home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Source Code 1992 March
/
Source_Code_CD-ROM_Walnut_Creek_March_1992.iso
/
msdos
/
c
/
jazlib.arc
/
JZSTRCAT.C
< prev
next >
Wrap
Text File
|
1986-08-15
|
1KB
|
36 lines
/*
┌────────────────────────────────────────────────────────────────────────────┐
│jzstrcat.c │
│Concatenate multiple strings together in one function call using a variable │
│number of parameters. │
│Simply put a null string (0) as the last argument in the function. │
│Synopsis: │
│ char *wdir,wstr[255]; │
│ │
│ *wdir = "MSC"; │
│ *wstr=0; │
│ │
│ jzstrcat(wstr,"\\",wdir,"\\","JAZ",0); │
│ │
│ (wstr now equals "\MSC\JAZ") │
└────────────────────────────────────────────────────────────────────────────┘
*/
jzstrcat(fstr,fparm)
char *fstr;
char *fparm;
{
int w;
/**
** We are going to loop through the addresses of the parmameters.
** Effectively looking at our arguments on the stack
**/
for (w = 0 ; *(&fparm + w) ; w ++) /* until we hit a null string */
strcat(fstr,*(&fparm + w)); /* reference the address of the parms */
}