home *** CD-ROM | disk | FTP | other *** search
Text File | 1995-10-18 | 21.7 KB | 2,270 lines |
- # 1 "zip.c"
-
-
-
-
-
-
-
-
-
-
- # 1 "/usr/include/ctype.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 1 "/usr/include/sys/cdefs.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 82 "/usr/include/sys/cdefs.h" 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 39 "/usr/include/ctype.h" 2 3
-
-
-
-
-
-
-
-
-
-
-
- extern const char *_ctype_;
- extern const short *_tolower_tab_;
- extern const short *_toupper_tab_;
-
-
- extern int isalnum (int) ;
- extern int isalpha (int) ;
- extern int iscntrl (int) ;
- extern int isdigit (int) ;
- extern int isgraph (int) ;
- extern int islower (int) ;
- extern int isprint (int) ;
- extern int ispunct (int) ;
- extern int isspace (int) ;
- extern int isupper (int) ;
- extern int isxdigit (int) ;
- extern int tolower (int) ;
- extern int toupper (int) ;
-
-
- extern int isblank (int) ;
- extern int isascii (int) ;
- extern int toascii (int) ;
- extern int _tolower (int) ;
- extern int _toupper (int) ;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 11 "zip.c" 2
-
- # 1 "/usr/include/sys/types.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 1 "/usr/include/machine/endian.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 94 "/usr/include/machine/endian.h" 3
-
-
-
- unsigned long htonl (unsigned long) ;
- unsigned short htons (unsigned short) ;
- unsigned long ntohl (unsigned long) ;
- unsigned short ntohs (unsigned short) ;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 128 "/usr/include/machine/endian.h" 3
-
-
-
- # 41 "/usr/include/sys/types.h" 2 3
-
-
- typedef unsigned char u_char;
- typedef unsigned short u_short;
- typedef unsigned int u_int;
- typedef unsigned long u_long;
- typedef unsigned short ushort;
-
- typedef char * caddr_t;
- typedef long daddr_t;
- typedef short dev_t;
- typedef u_long ino_t;
- typedef long off_t;
- typedef u_short nlink_t;
- typedef long swblk_t;
- typedef long segsz_t;
- typedef u_short uid_t;
- typedef u_short gid_t;
- typedef short pid_t;
- typedef u_short mode_t;
- typedef u_long fixpt_t;
- typedef int ssize_t;
-
-
- typedef struct _uquad { u_long val[2]; } u_quad;
- typedef struct _quad { long val[2]; } quad;
- typedef unsigned long long u_quad_t;
- typedef long long quad_t;
- typedef quad_t * qaddr_t;
-
-
-
-
-
-
- # 1 "/usr/include/machine/ansi.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 76 "/usr/include/sys/types.h" 2 3
-
-
- # 1 "/usr/include/machine/types.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef struct _physadr {
- short r[1];
- } *physadr;
-
- typedef struct label_t {
- int val[15];
- } label_t;
-
- typedef u_long vm_offset_t;
- typedef u_long vm_size_t;
-
-
- # 78 "/usr/include/sys/types.h" 2 3
-
-
-
-
- typedef unsigned long clock_t;
-
-
-
-
- typedef unsigned int size_t;
-
-
-
-
- typedef long time_t;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef long fd_mask;
-
-
-
-
-
-
- typedef struct fd_set {
- fd_mask fds_bits[((( 256 )+(( (sizeof(fd_mask) * 8 ) )-1))/( (sizeof(fd_mask) * 8 ) )) ];
- } fd_set;
-
-
-
-
-
-
- # 139 "/usr/include/sys/types.h" 3
-
-
-
-
-
- # 12 "zip.c" 2
-
-
- # 1 "tailor.h" 1
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 65 "tailor.h"
-
-
-
-
- # 109 "tailor.h"
-
-
- # 130 "tailor.h"
-
-
- # 144 "tailor.h"
-
-
-
-
-
-
-
-
-
- # 172 "tailor.h"
-
-
- # 194 "tailor.h"
-
-
- # 215 "tailor.h"
-
-
- # 230 "tailor.h"
-
-
- # 250 "tailor.h"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 14 "zip.c" 2
-
- # 1 "gzip.h" 1
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef void *voidp;
-
-
-
-
-
-
-
- # 1 "/usr/include/stdio.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef long fpos_t;
-
-
-
-
-
-
-
-
-
-
- struct __sbuf {
- unsigned char *_base;
- int _size;
- };
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef struct __sFILE {
- unsigned char *_p;
- int _r;
- int _w;
- short _flags;
- short _file;
- struct __sbuf _bf;
- int _lbfsize;
-
-
- void *_cookie;
- int (*_close) (void *) ;
- int (*_read) (void *, char *, int) ;
- fpos_t (*_seek) (void *, fpos_t, int) ;
- int (*_write) (void *, const char *, int) ;
-
-
- struct __sbuf _ub;
- unsigned char *_up;
- int _ur;
-
-
- unsigned char _ubuf[3];
- unsigned char _nbuf[1];
-
-
- struct __sbuf _lb;
-
-
- int _blksize;
- int _offset;
- } FILE;
-
-
- extern FILE __sF[];
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- void clearerr (FILE *) ;
- int fclose (FILE *) ;
- int feof (FILE *) ;
- int ferror (FILE *) ;
- int fflush (FILE *) ;
- int fgetc (FILE *) ;
- int fgetpos (FILE *, fpos_t *) ;
- char *fgets (char *, size_t, FILE *) ;
- FILE *fopen (const char *, const char *) ;
- int fprintf (FILE *, const char *, ...) ;
- int fputc (int, FILE *) ;
- int fputs (const char *, FILE *) ;
- size_t fread (void *, size_t, size_t, FILE *) ;
- FILE *freopen (const char *, const char *, FILE *) ;
- int fscanf (FILE *, const char *, ...) ;
- int fseek (FILE *, long, int) ;
- int fsetpos (FILE *, const fpos_t *) ;
- long ftell (const FILE *) ;
- size_t fwrite (const void *, size_t, size_t, FILE *) ;
- int getc (FILE *) ;
- int getchar (void) ;
- char *gets (char *) ;
-
- extern int sys_nerr;
- extern const char *const sys_errlist[];
-
- void perror (const char *) ;
- int printf (const char *, ...) ;
- int putc (int, FILE *) ;
- int putchar (int) ;
- int puts (const char *) ;
- int remove (const char *) ;
- int rename (const char *, const char *) ;
- void rewind (FILE *) ;
- int scanf (const char *, ...) ;
- void setbuf (FILE *, char *) ;
- int setvbuf (FILE *, char *, int, size_t) ;
- int sprintf (char *, const char *, ...) ;
- int sscanf (const char *, const char *, ...) ;
- FILE *tmpfile (void) ;
- char *tmpnam (char *) ;
- int ungetc (int, FILE *) ;
- int vfprintf (FILE *, const char *, char * ) ;
- int vprintf (const char *, char * ) ;
- int vsprintf (char *, const char *, char * ) ;
-
-
-
-
-
-
-
-
-
-
- char *ctermid (char *) ;
- char *cuserid (char *) ;
- FILE *fdopen (int, const char *) ;
- int fileno (FILE *) ;
-
-
-
-
-
-
-
-
- char *fgetline (FILE *, size_t *) ;
- int fpurge (FILE *) ;
- int getw (FILE *) ;
- int pclose (FILE *) ;
- FILE *popen (const char *, const char *) ;
- int putw (int, FILE *) ;
- void setbuffer (FILE *, char *, int) ;
- int setlinebuf (FILE *) ;
- char *tempnam (const char *, const char *) ;
- int snprintf (char *, size_t, const char *, ...)
- __attribute__((format (printf, 3, 4)));
- int vsnprintf (char *, size_t, const char *, char * )
- __attribute__((format (printf, 3, 0)));
- int vscanf (const char *, char * )
- __attribute__((format (scanf, 1, 0)));
- int vsscanf (const char *, const char *, char * )
- __attribute__((format (scanf, 2, 0)));
-
-
-
-
-
-
-
-
-
-
-
-
-
- FILE *funopen (const void *,
- int (*)(void *, char *, int),
- int (*)(void *, const char *, int),
- fpos_t (*)(void *, fpos_t, int),
- int (*)(void *)) ;
-
-
-
-
-
-
-
-
-
- int __srget (FILE *) ;
- int __svfscanf (FILE *, const char *, char * ) ;
- int __swbuf (int, FILE *) ;
-
-
-
-
-
-
-
-
- static __inline int __sputc(int _c, FILE *_p) {
- if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n'))
- return (*_p->_p++ = _c);
- else
- return (__swbuf(_c, _p));
- }
- # 337 "/usr/include/stdio.h" 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 22 "gzip.h" 2
-
-
- # 1 "/usr/include/string.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- void *memchr (const void *, int, size_t) ;
-
-
-
-
- void *memmove (void *, const void *, size_t) ;
- void *memset (void *, int, size_t) ;
- char *strcat (char *, const char *) ;
- char *strchr (const char *, int) ;
- int strcmp (const char *, const char *) ;
- int strcoll (const char *, const char *) ;
- char *strcpy (char *, const char *) ;
- size_t strcspn (const char *, const char *) ;
- char *strerror (int) ;
- size_t strlen (const char *) ;
- char *strncat (char *, const char *, size_t) ;
- int strncmp (const char *, const char *, size_t) ;
- char *strncpy (char *, const char *, size_t) ;
- char *strpbrk (const char *, const char *) ;
- char *strrchr (const char *, int) ;
- size_t strspn (const char *, const char *) ;
- char *strstr (const char *, const char *) ;
- char *strtok (char *, const char *) ;
- size_t strxfrm (char *, const char *, size_t) ;
-
-
-
- int bcmp (const void *, const void *, size_t) ;
- void bcopy (const void *, void *, size_t) ;
- void bzero (void *, size_t) ;
- int ffs (int) ;
- char *index (const char *, int) ;
- void *memccpy (void *, const void *, int, size_t) ;
- char *rindex (const char *, int) ;
- int strcasecmp (const char *, const char *) ;
- char *strdup (const char *) ;
- void strmode (int, char *) ;
- int strncasecmp (const char *, const char *, size_t) ;
- char *strsep (char **, const char *) ;
- void swab (const void *, void *, size_t) ;
-
-
-
-
- # 24 "gzip.h" 2
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- typedef unsigned char uch;
- typedef unsigned short ush;
- typedef unsigned long ulg;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- extern int method;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 108 "gzip.h"
-
-
-
-
-
-
-
- extern uch inbuf [] ;
- extern uch outbuf [] ;
- extern ush d_buf [] ;
- extern uch window [] ;
-
-
-
-
- extern ush prev [] ;
-
-
-
-
-
-
-
- extern unsigned insize;
- extern unsigned inptr;
- extern unsigned outcnt;
-
- extern long bytes_in;
- extern long bytes_out;
- extern long header_bytes;
-
-
-
-
- extern int ifd;
- extern int ofd;
- extern char ifname[];
- extern char ofname[];
- extern char *progname;
-
- extern long time_stamp;
- extern long ifile_size;
-
- typedef int file_t;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- extern int decrypt;
- extern int exit_code;
- extern int verbose;
- extern int quiet;
- extern int level;
- extern int test;
- extern int to_stdout;
- extern int save_orig_name;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 225 "gzip.h"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- extern int zip (int in, int out) ;
- extern int file_read (char *buf, unsigned size) ;
-
-
- extern int unzip (int in, int out) ;
- extern int check_zipfile (int in) ;
-
-
- extern int unpack (int in, int out) ;
-
-
- extern int unlzh (int in, int out) ;
-
-
- void abort_gzip (void) ;
-
-
- void lm_init (int pack_level, ush *flags) ;
- ulg deflate (void) ;
-
-
- void ct_init (ush *attr, int *method) ;
- int ct_tally (int dist, int lc) ;
- ulg flush_block (char *buf, ulg stored_len, int eof) ;
-
-
- void bi_init (file_t zipfile) ;
- void send_bits (int value, int length) ;
- unsigned bi_reverse (unsigned value, int length) ;
- void bi_windup (void) ;
- void copy_block (char *buf, unsigned len, int header) ;
- extern int (*read_buf) (char *buf, unsigned size) ;
-
-
- extern int copy (int in, int out) ;
- extern ulg updcrc (uch *s, unsigned n) ;
- extern void clear_bufs (void) ;
- extern int fill_inbuf (int eof_ok) ;
- extern void flush_outbuf (void) ;
- extern void flush_window (void) ;
- extern void write_buf (int fd, voidp buf, unsigned cnt) ;
- extern char *strlwr (char *s) ;
- extern char *basename (char *fname) ;
- extern void make_simple_name (char *name) ;
- extern char *add_envopt (int *argcp, char ***argvp, char *env) ;
- extern void error (char *m) ;
- extern void warn (char *a, char *b) ;
- extern void read_error (void) ;
- extern void write_error (void) ;
- extern void display_ratio (long num, long den, FILE *file) ;
- extern voidp xmalloc (unsigned int size) ;
-
-
- extern int inflate (void) ;
- # 15 "zip.c" 2
-
- # 1 "crypt.h" 1
-
-
-
-
-
-
-
-
-
-
-
-
- # 16 "zip.c" 2
-
-
-
- # 1 "/usr/include/unistd.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 1 "/usr/include/sys/unistd.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 42 "/usr/include/unistd.h" 2 3
-
-
-
-
-
-
-
-
-
-
-
- __volatile void _exit (int) ;
- int access (const char *, int) ;
- unsigned alarm (unsigned) ;
- int chdir (const char *) ;
- int chown (const char *, uid_t, gid_t) ;
- int close (int) ;
- size_t confstr (int, char *, size_t) ;
- char *cuserid (char *) ;
- int dup (int) ;
- int dup2 (int, int) ;
- int execl (const char *, const char *, ...) ;
- int execle (const char *, const char *, ...) ;
- int execlp (const char *, const char *, ...) ;
- int execv (const char *, char * const *) ;
- int execve (const char *, char * const *, char * const *) ;
- int execvp (const char *, char * const *) ;
- pid_t fork (void) ;
- long fpathconf (int, int) ;
- char *getcwd (char *, size_t) ;
- gid_t getegid (void) ;
- uid_t geteuid (void) ;
- gid_t getgid (void) ;
- int getgroups (int, int *) ;
- char *getlogin (void) ;
- pid_t getpgrp (void) ;
- pid_t getpid (void) ;
- pid_t getppid (void) ;
- uid_t getuid (void) ;
- int isatty (int) ;
- int link (const char *, const char *) ;
- off_t lseek (int, off_t, int) ;
- long pathconf (const char *, int) ;
- int pause (void) ;
- int pipe (int *) ;
- ssize_t read (int, void *, size_t) ;
- int rmdir (const char *) ;
- int setgid (gid_t) ;
- int setpgid (pid_t, pid_t) ;
- pid_t setsid (void) ;
- int setuid (uid_t) ;
- unsigned sleep (unsigned) ;
- long sysconf (int) ;
- pid_t tcgetpgrp (int) ;
- int tcsetpgrp (int, pid_t) ;
- char *ttyname (int) ;
- int unlink (const char *) ;
- ssize_t write (int, const void *, size_t) ;
-
-
-
-
- # 1 "/usr/include/sys/time.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- struct timeval {
- long tv_sec;
- long tv_usec;
- };
-
- struct timezone {
- int tz_minuteswest;
- int tz_dsttime;
- };
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- struct itimerval {
- struct timeval it_interval;
- struct timeval it_value;
- };
-
-
-
-
-
-
-
-
- # 1 "/usr/include/time.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- struct tm {
- int tm_sec;
- int tm_min;
- int tm_hour;
- int tm_mday;
- int tm_mon;
- int tm_year;
- int tm_wday;
- int tm_yday;
- int tm_isdst;
- long tm_gmtoff;
- char *tm_zone;
- };
-
-
-
-
- char *asctime (const struct tm *) ;
- clock_t clock (void) ;
- char *ctime (const time_t *) ;
- double difftime (time_t, time_t) ;
- struct tm *gmtime (const time_t *) ;
- struct tm *localtime (const time_t *) ;
- time_t mktime (struct tm *) ;
- size_t strftime (char *, size_t, const char *, const struct tm *) ;
- time_t time (time_t *) ;
-
-
-
- char *tzname[2];
- void tzset (void) ;
-
-
-
- char *timezone (int, int) ;
- void tzsetwall (void) ;
-
-
-
-
- # 92 "/usr/include/sys/time.h" 2 3
-
-
-
-
-
-
- int adjtime (const struct timeval *, struct timeval *) ;
- int getitimer (int, struct itimerval *) ;
- int gettimeofday (struct timeval *, struct timezone *) ;
- int setitimer (int, const struct itimerval *, struct itimerval *) ;
- int settimeofday (const struct timeval *, const struct timezone *) ;
- int utimes (const char *, const struct timeval *) ;
-
-
-
-
-
-
- # 104 "/usr/include/unistd.h" 2 3
-
-
- int acct (const char *) ;
- int async_daemon (void) ;
- char *brk (const char *) ;
- int chflags (const char *, long) ;
- int chroot (const char *) ;
- char *crypt (const char *, const char *) ;
- int des_cipher (const char *, char *, long, int) ;
- int des_setkey (const char *key) ;
- int encrypt (char *, int) ;
- void endusershell (void) ;
- int exect (const char *, char * const *, char * const *) ;
- int fchdir (int) ;
- int fchflags (int, long) ;
- int fchown (int, int, int) ;
- int fsync (int) ;
- int ftruncate (int, off_t) ;
- int getdomainname (char *, int) ;
- int getdtablesize (void) ;
- long gethostid (void) ;
- int gethostname (char *, int) ;
- mode_t getmode (const void *, mode_t) ;
- int getpagesize (void) ;
- char *getpass (const char *) ;
- char *getusershell (void) ;
- char *getwd (char *) ;
- int initgroups (const char *, int) ;
- int mknod (const char *, mode_t, dev_t) ;
- int mkstemp (char *) ;
- char *mktemp (char *) ;
- int nfssvc (int) ;
- int nice (int) ;
- void psignal (u_int, const char *) ;
- extern const char *const sys_siglist[];
- extern const char *const sys_signame[];
- int profil (char *, int, int, int) ;
- int rcmd (char **, int, const char *,
- const char *, const char *, int *) ;
- char *re_comp (const char *) ;
- int re_exec (const char *) ;
- int readlink (const char *, char *, int) ;
- int reboot (int) ;
- int revoke (const char *) ;
- int rresvport (int *) ;
- int ruserok (const char *, int, const char *, const char *) ;
- char *sbrk (int) ;
- int select (int, fd_set *, fd_set *, fd_set *, struct timeval *) ;
- int setdomainname (const char *, int) ;
- int setegid (gid_t) ;
- int seteuid (uid_t) ;
- int setgroups (int, const int *) ;
- void sethostid (long) ;
- int sethostname (const char *, int) ;
- int setkey (const char *) ;
- int setlogin (const char *) ;
- void *setmode (const char *) ;
- int setpgrp (pid_t pid, pid_t pgrp) ;
- int setregid (int, int) ;
- int setreuid (int, int) ;
- int setrgid (gid_t) ;
- int setruid (uid_t) ;
- void setusershell (void) ;
- int swapon (const char *) ;
- int symlink (const char *, const char *) ;
- void sync (void) ;
- int syscall (int, ...) ;
- int truncate (const char *, off_t) ;
- int ttyslot (void) ;
- u_int ualarm (u_int, u_int) ;
- void usleep (u_int) ;
- void *valloc (size_t) ;
- int vfork (void) ;
-
- int getopt (int, char * const *, const char *) ;
- extern char *optarg;
- extern int opterr;
- extern int optind;
- extern int optopt;
- int getsubopt (char **, char * const *, char **) ;
- extern char *suboptarg;
-
-
-
-
- # 19 "zip.c" 2
-
-
-
- # 1 "/usr/include/fcntl.h" 1 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- # 100 "/usr/include/fcntl.h" 3
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- struct flock {
- short l_type;
- short l_whence;
- off_t l_start;
- off_t l_len;
- pid_t l_pid;
- };
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- int open (const char *, int, ...) ;
- int creat (const char *, mode_t) ;
- int fcntl (int, int, ...) ;
-
- int flock (int, int) ;
-
-
-
-
-
- # 22 "zip.c" 2
-
-
-
- static ulg crc;
- long header_bytes;
-
-
-
-
-
-
- int zip(in, out)
- int in, out;
- {
- uch flags = 0;
- ush attr = 0;
- ush deflate_flags = 0;
-
- ifd = in;
- ofd = out;
- outcnt = 0;
-
-
-
- method = 8 ;
- {outbuf[outcnt++]=(uch)( "\037\213" [0] ); if (outcnt== 16384 ) flush_outbuf();} ;
- {outbuf[outcnt++]=(uch)( "\037\213" [1] ); if (outcnt== 16384 ) flush_outbuf();} ;
- {outbuf[outcnt++]=(uch)( 8 ); if (outcnt== 16384 ) flush_outbuf();} ;
-
- if (save_orig_name) {
- flags |= 0x08 ;
- }
- {outbuf[outcnt++]=(uch)( flags ); if (outcnt== 16384 ) flush_outbuf();} ;
- { { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ( time_stamp ) & 0xffff ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ( time_stamp ) & 0xffff ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ( time_stamp ) & 0xffff ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ( time_stamp ) & 0xffff ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ((ulg)( time_stamp )) >> 16 ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ((ulg)( time_stamp )) >> 16 ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ((ulg)( time_stamp )) >> 16 ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ((ulg)( time_stamp )) >> 16 ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; } ;
-
-
- crc = updcrc(0, 0);
-
- bi_init(out);
- ct_init(&attr, &method);
- lm_init(level, &deflate_flags);
-
- {outbuf[outcnt++]=(uch)( (uch)deflate_flags ); if (outcnt== 16384 ) flush_outbuf();} ;
- {outbuf[outcnt++]=(uch)( 0x03 ); if (outcnt== 16384 ) flush_outbuf();} ;
-
- if (save_orig_name) {
- char *p = basename(ifname);
- do {
- {outbuf[outcnt++]=(uch)( *p ); if (outcnt== 16384 ) flush_outbuf();} ;
- } while (*p++);
- }
- header_bytes = (long)outcnt;
-
- (void)deflate();
-
- # 86 "zip.c"
-
-
-
- { { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ( crc ) & 0xffff ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ( crc ) & 0xffff ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ( crc ) & 0xffff ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ( crc ) & 0xffff ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ((ulg)( crc )) >> 16 ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ((ulg)( crc )) >> 16 ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ((ulg)( crc )) >> 16 ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ((ulg)( crc )) >> 16 ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; } ;
- { { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ( bytes_in ) & 0xffff ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ( bytes_in ) & 0xffff ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ( bytes_in ) & 0xffff ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ( bytes_in ) & 0xffff ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; { if (outcnt < 16384 -2) { outbuf[outcnt++] = (uch) (( ((ulg)( bytes_in )) >> 16 ) & 0xff); outbuf[outcnt++] = (uch) ((ush)( ((ulg)( bytes_in )) >> 16 ) >> 8); } else { {outbuf[outcnt++]=(uch)( (uch)(( ((ulg)( bytes_in )) >> 16 ) & 0xff) ); if (outcnt== 16384 ) flush_outbuf();} ; {outbuf[outcnt++]=(uch)( (uch)((ush)( ((ulg)( bytes_in )) >> 16 ) >> 8) ); if (outcnt== 16384 ) flush_outbuf();} ; } } ; } ;
- header_bytes += 2*sizeof(long);
-
- flush_outbuf();
- return 0 ;
- }
-
-
-
-
-
-
-
- int file_read(buf, size)
- char *buf;
- unsigned size;
- {
- unsigned len;
-
- ;
-
- len = read(ifd, buf, size);
- if (len == (unsigned)(-1) || len == 0) return (int)len;
-
- crc = updcrc((uch*)buf, len);
- bytes_in += (ulg)len;
- return (int)len;
- }
-