1 | /* ckclib.h -- C-Kermit library routine prototypes */ |
---|
2 | /* |
---|
3 | Author: Frank da Cruz <fdc@columbia.edu>, |
---|
4 | Columbia University Academic Information Systems, New York City. |
---|
5 | |
---|
6 | Copyright (C) 2002, |
---|
7 | Trustees of Columbia University in the City of New York. |
---|
8 | All rights reserved. See the C-Kermit COPYING.TXT file or the |
---|
9 | copyright text in the ckcmai.c module for disclaimer and permissions. |
---|
10 | */ |
---|
11 | #ifndef CKCLIB_H |
---|
12 | #define CKCLIB_H |
---|
13 | |
---|
14 | struct stringarray { |
---|
15 | char ** a_head; |
---|
16 | int a_size; |
---|
17 | }; |
---|
18 | |
---|
19 | #ifdef CK_ANSIC |
---|
20 | _PROTOTYP( int ckstrncpy, (char *, const char *, int) ); |
---|
21 | _PROTOTYP( int ckstrncat, (char *, const char *, int) ); |
---|
22 | #else |
---|
23 | _PROTOTYP( int ckstrncpy, (char *, char *, int) ); |
---|
24 | _PROTOTYP( int ckstrncat, (char *, char *, int) ); |
---|
25 | #endif /* CK_ANSIC */ |
---|
26 | |
---|
27 | _PROTOTYP( int ckmakmsg, (char *, int, char *, char *, char *, char *) ); |
---|
28 | _PROTOTYP( int ckmakxmsg, (char *, int, |
---|
29 | char *, char *, char *, char *, char *, char *, |
---|
30 | char *, char *, char *, char *, char *, char *) ); |
---|
31 | |
---|
32 | _PROTOTYP( char * ckstrpbrk, (char *, char *) ); |
---|
33 | _PROTOTYP( char * ckstrstr, (char *, char *) ); |
---|
34 | _PROTOTYP( char * chartostr, (int) ); |
---|
35 | _PROTOTYP( int cklower, (char *) ); |
---|
36 | _PROTOTYP( int ckupper, (char *) ); |
---|
37 | _PROTOTYP( int ckindex, (char *, char *, int, int, int) ); |
---|
38 | _PROTOTYP( char * ckctoa, (char) ); |
---|
39 | _PROTOTYP( char * ckctox, (CHAR, int) ); |
---|
40 | _PROTOTYP( char * ckitoa, (int) ); |
---|
41 | _PROTOTYP( char * ckuitoa, (unsigned int) ); |
---|
42 | _PROTOTYP( char * ckltoa, (long) ); |
---|
43 | _PROTOTYP( char * ckultoa, (unsigned long) ); |
---|
44 | _PROTOTYP( char * ckitox, (int) ); |
---|
45 | _PROTOTYP( char * ckltox, (long) ); |
---|
46 | _PROTOTYP( int ckmatch, (char *, char *, int, int ) ); |
---|
47 | _PROTOTYP( VOID ckmemcpy, (char *, char *, int) ); |
---|
48 | _PROTOTYP( char * ckstrchr, (char *, char) ); |
---|
49 | _PROTOTYP( char * ckstrrchr, (char *, char) ); |
---|
50 | _PROTOTYP( int ckrchar, (char *) ); |
---|
51 | _PROTOTYP( int ckstrcmp, (char *, char *, int, int) ); |
---|
52 | #define xxstrcmp(a,b,c) ckstrcmp(a,b,c,0) |
---|
53 | _PROTOTYP( int ckstrpre, (char *, char *) ); |
---|
54 | _PROTOTYP( VOID sh_sort, (char **, char **, int, int, int, int) ); |
---|
55 | _PROTOTYP( char * brstrip, (char *) ); |
---|
56 | _PROTOTYP( char * fnstrip, (char *) ); |
---|
57 | #ifdef COMMENT |
---|
58 | _PROTOTYP( char * brace, (char *) ); |
---|
59 | #endif /* COMMENT */ |
---|
60 | _PROTOTYP( int dquote, (char *, int, int) ); |
---|
61 | _PROTOTYP( VOID makelist, (char *, char *[], int) ); |
---|
62 | #ifndef CK_ANSIC |
---|
63 | _PROTOTYP( VOID makestr, (char **, char *) ); |
---|
64 | _PROTOTYP( VOID xmakestr, (char **, char *) ); |
---|
65 | #else /* CK_ANSIC */ |
---|
66 | _PROTOTYP( VOID makestr, (char **, const char *) ); |
---|
67 | _PROTOTYP( VOID xmakestr, (char **, const char *) ); |
---|
68 | #endif /* CK_ANSIC */ |
---|
69 | _PROTOTYP( int chknum, (char *) ); |
---|
70 | _PROTOTYP( int rdigits, (char *) ); |
---|
71 | _PROTOTYP( char * ckradix, (char *,int,int) ); |
---|
72 | |
---|
73 | /* Base-64 conversion needed for script programming and HTTP */ |
---|
74 | |
---|
75 | #ifndef NOB64 |
---|
76 | _PROTOTYP( int b8tob64, (char *,int,char *,int)); |
---|
77 | _PROTOTYP( int b64tob8, (char *,int,char *,int)); |
---|
78 | #endif /* NOB64 */ |
---|
79 | |
---|
80 | #ifdef CKFLOAT |
---|
81 | _PROTOTYP( int isfloat, (char *,int) ); |
---|
82 | #ifndef CKCLIB_C |
---|
83 | #ifndef CKWART_C |
---|
84 | extern CKFLOAT floatval; |
---|
85 | #endif /* CKWART_C */ |
---|
86 | #endif /* CKCLIB_C */ |
---|
87 | #endif /* CKFLOAT */ |
---|
88 | |
---|
89 | _PROTOTYP( char * parnam, (char) ); |
---|
90 | _PROTOTYP( char *hhmmss, (long) ); |
---|
91 | |
---|
92 | _PROTOTYP( VOID lset, (char *, char *, int, int) ); |
---|
93 | _PROTOTYP( VOID rset, (char *, char *, int, int) ); |
---|
94 | _PROTOTYP( char * ulongtohex, (unsigned long, int) ); |
---|
95 | _PROTOTYP( long hextoulong, (char *, int) ); |
---|
96 | _PROTOTYP( struct stringarray * cksplit, (int,int, |
---|
97 | char *,char *,char *,int,int,int) ); |
---|
98 | |
---|
99 | #endif /* CKCLIB_H */ |
---|