This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

question about snprintf and vsnprintf


hello cygwinners,

recently we came across both of the routines mentioned above while porting
some software. Both, snprintf and vsnprintf are not defined in any of the
headers, whether cygwin nor mingw. They should be defined in stdio.h like

int _snprintf(char *str, size_t n, const char *format, ...);
int _vsnprintf(char *buffer,size_t count,const char *format,va_list argptr);

and as all the ctrdll.dll routine there should be a define like

#define snprintf _snprintf
#define vsnprintf _vsnprintf

Both routines can be found within the libcrtdll.a and of course within the
Windows's crtdll.dll. I could not find it in the cygwin1.dll.

I do not a good reason why not to implement it there.

We are using the Win95 Patch "cygwin-inst-19990115.tar.gz" under Windows
95 4.0 and the normal release "Cygwin B20.1" under Windows NT 4.0 build
1381. We solved our problem with it using the -mno-cygwin option and the
mingw32 extra files defining the above thingies.

Was there any reason for this ?
Thanks in advance and maybe this will help you ?

Stefan. 
Please email directly as well, because i did not join the mailing list yet.


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]