OSDN Git Service

use the tmpfile() function to create temporary file.
[lha/olha.git] / prototypes.h
1 /* This file was generated by cproto. */
2 #if PROTOTYPES /* defined in config.h */
3 #define P_(s) s
4 #else
5 #define P_(s) ()
6 #endif
7
8 /* ar.c */
9 struct lha_method *which_method P_((char *id));
10 uint ratio P_((ulong a, ulong b));
11 void skip P_((FILE *fp, struct lzh_header *h));
12 int get_line P_((char *s, int n));
13 void parse_args P_((int argc, char **argv));
14 FILE *open_tempfile P_((void));
15 /* io.c */
16 void make_crctable P_((void));
17 void fillbuf P_((struct lzh_istream *rp, int n));
18 uint getbits P_((struct lzh_istream *rp, int n));
19 void putbits P_((struct lzh_ostream *wp, int n, uint x));
20 int fread_crc P_((void *p, int n, FILE *f, unsigned int *crc));
21 void fwrite_crc P_((void *p, int n, FILE *f, unsigned int *crc));
22 void init_getbits P_((struct lzh_istream *rp));
23 void init_putbits P_((struct lzh_ostream *wp));
24 /* encode.c */
25 void encode P_((struct lzh_ostream *wp, FILE *rfp));
26 /* decode.c */
27 void decode P_((struct lzh_istream *rp, FILE *outfile, unsigned long remainder, unsigned int *crc));
28 /* maketree.c */
29 int make_tree P_((uint16_t nparm, uint16_t *freqparm, uint8_t *lenparm, uint16_t *codeparm));
30 /* maketbl.c */
31 void make_table P_((struct huf_t *huf, int nchar, uchar bitlen[], int tablebits, ushort table[]));
32 /* huf.c */
33 void output P_((struct lzh_ostream *wp, uint c, uint p));
34 void huf_encode_start P_((struct lzh_ostream *wp, struct lha_method *m));
35 void huf_encode_end P_((struct lzh_ostream *wp));
36 uint decode_c P_((struct huf_t *huf, struct lzh_istream *rp));
37 uint decode_p P_((struct huf_t *huf, struct lzh_istream *rp));
38 void huf_decode_start P_((struct lzh_istream *rp, struct lha_method *m));
39 /* strlib.c */
40 int string_equal P_((char *str1, char *str2));
41 int string_copy P_((char *dst, char *src, int dstsz));
42 char *string_pcopy P_((char *dst, char *src, int dstsz));
43 int string_cat P_((char *dst, int dstsz, ...));
44 char *string_tail P_((char *str));
45 int chomp P_((char *s));
46 char *skip_space P_((char *s));
47 char *skip_to_space P_((char *s));
48 char *next_field P_((char *s));
49 char *strip_space P_((char *s));
50 /* pathlib.c */
51 int path_addsep P_((char *path, size_t size));
52 char *xbasename P_((char *path));
53 int makepath P_((char *dest, int dest_size, char *dir, char *file, char *ext));
54 /* filelib.c */
55 int file_exists P_((char *file));
56 int file_mtime P_((char *file, time_t *t));
57 int copy_stream P_((FILE *rfp, FILE *wfp));
58 int move_file_to_stream P_((char *file, FILE *wfp));
59 int copy_stream_to_file P_((FILE *rfp, char *file));
60 int xrename P_((char *from, char *to));
61 /* header.c */
62 int read_header P_((FILE *fp, struct lzh_header *h));
63 void write_header P_((FILE *fp, struct lzh_header *h));
64 /* add.c */
65 int add_dir P_((struct lzh_ostream *wp, int replace_flag, struct lzh_header *h));
66 int add P_((struct lzh_ostream *wp, int replace_flag, char *filename, int namelen));
67 /* extract.c */
68 void extract P_((struct lzh_istream *rp, int to_file, struct lzh_header *h));
69 /* list.c */
70 void list_start P_((void));
71 void list P_((struct lzh_header *h));
72 /* error.c */
73 void error P_((char *fmt, ...));
74 void message P_((char *fmt, ...));
75 void warn P_((char *fmt, ...));