mirror of
https://github.com/lcn2/calc.git
synced 2025-08-16 01:03:29 +03:00
Release calc version 2.11.0t3
This commit is contained in:
@@ -52,7 +52,7 @@ char buf[BUFSIZ];
|
||||
#include <varargs.h>
|
||||
|
||||
void
|
||||
try(char *fmt, ...)
|
||||
try_this(char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
@@ -68,7 +68,7 @@ try(char *fmt, ...)
|
||||
#else
|
||||
|
||||
void
|
||||
try(char *a, int b, char *c, int d)
|
||||
try_this(char *a, int b, char *c, int d)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -87,7 +87,7 @@ main(void)
|
||||
/*
|
||||
* test variable args and vsprintf/sprintf
|
||||
*/
|
||||
try("@%d:%s:%d@", 1, "hi", 2);
|
||||
try_this("@%d:%s:%d@", 1, "hi", 2);
|
||||
if (strcmp(buf, "@1:hi:2@") != 0) {
|
||||
#if !defined(DONT_HAVE_VSPRINTF)
|
||||
/* <varargs.h> with vsprintf() didn't work */
|
||||
@@ -96,7 +96,7 @@ main(void)
|
||||
#endif
|
||||
exit(1);
|
||||
}
|
||||
try("%s %d%s%d%d %s",
|
||||
try_this("%s %d%s%d%d %s",
|
||||
"Landon Noll 1st proved that", 2, "^", 23209, -1, "was prime");
|
||||
if (strcmp(buf,
|
||||
"Landon Noll 1st proved that 2^23209-1 was prime") != 0) {
|
||||
|
Reference in New Issue
Block a user