home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power Programming
/
powerprogramming1994.iso
/
progtool
/
c
/
abmake14.arc
/
tstring.h
< prev
Wrap
Text File
|
1988-11-21
|
757b
|
31 lines
/*
* tstring.h
*
* 88-10-01 v1.0 created by greg yachuk, placed in the public domain
* 88-10-06 v1.1 changed prerequisite list handling
*
*/
#define tnew(t) ((t *) talloc(sizeof(t)))
#define tstrcat(s,p) (strcat(strcpy(talloc(strlen(s)+strlen(p)+1),(s)),(p)))
#define tstrcpy(s) (strlen(s) ? strcpy(talloc(strlen(s)+1), (s)): NULL)
#ifdef MSDOS
void tfree(void *s);
void *talloc(int n);
void *trealloc(void *s, int n);
void *tstrncpy(void *s, int n);
int terror(int n, char *s);
char *token(char *s, char *sep);
char **tokenize(char *input);
char *tgets(FILE *fd);
#else
char *talloc();
char *trealloc();
char *tstrncpy();
int terror();
char *token();
char **tokenize();
char *tgets();
#endif