problem with varargs.h in Xenix 2.3.3
    Perry L. Statham 
    statham at cactus.org
       
    Thu Apr 25 10:28:54 AEST 1991
    
    
  
/*
Can anyone tell me why this program does not compile and how to fix it.
Operating System:
    SCO Xenix 2.3.3
    Dev Kit Release 2.3.0d
        
Compiler Message:
    testprog.c(19) : error 65: 'va_alist' : undefined
Line 19 is the line that has va_start on it.
The release lines for the two header files are:
    *	@(#) stdio.h 1.10 88/10/26 
    *	@(#) varargs.h 1.1 88/10/26 
Any help is appreciated.
Perry Statham
perry at statham.cactus.org
(512) 335-3881 (Home)
(512) 467-1396 (Work)
*/
#include <stdio.h>
#include <varargs.h>
void sceprintf( char *, 
                ... );  
main() {
  sceprintf("0x%x %d\n",1,1);
}
void sceprintf( format, ... )
char *format;
{
  FILE *log;
  va_list argptr;
  if ((log = fopen("logfile","a+")) != NULL) {
    va_start(argptr);
    vfprintf(log,format,argptr);
    va_end(argptr);
    fclose(log);
  }
} 
    
    
More information about the Comp.unix.xenix.sco
mailing list