From 5d65e1ca926b8a5cd5e5c3085466749fd310989f Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 23 Nov 2008 19:44:29 +0000 Subject: [PATCH] gcc-4.3 warning fixes git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10939 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Source/Modules/modula3.cxx | 6 +++--- Source/Modules/php.cxx | 6 ++++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Source/Modules/modula3.cxx b/Source/Modules/modula3.cxx index e85ba3a46..1df206e62 100644 --- a/Source/Modules/modula3.cxx +++ b/Source/Modules/modula3.cxx @@ -127,7 +127,7 @@ char cvsroot_modula3_cxx[] = "$Id$"; #include // for INT_MAX #include -const char usageArgDir[] = "m3wrapargdir typemap expect values: in, out, inout\n"; +#define USAGE_ARG_DIR "m3wrapargdir typemap expect values: in, out, inout\n" class MODULA3:public Language { public: @@ -374,7 +374,7 @@ MODULA3(): } else if (Strcmp(dir, "out") == 0) { return false; } else { - printf(usageArgDir); + printf(USAGE_ARG_DIR); return false; } } @@ -386,7 +386,7 @@ MODULA3(): } else if ((Strcmp(dir, "out") == 0) || (Strcmp(dir, "inout") == 0)) { return true; } else { - printf(usageArgDir); + printf(USAGE_ARG_DIR); return false; } } diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index 434456b40..0b6036669 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -1101,7 +1101,8 @@ public: case T_LONG: { char *p; errno = 0; - (void) strtol(Char(value), &p, 0); + unsigned int n = strtol(Char(value), &p, 0); + (void) n; if (errno || *p) { Clear(value); Append(value, "?"); @@ -1114,7 +1115,8 @@ public: case T_ULONG: { char *p; errno = 0; - (void) strtoul(Char(value), &p, 0); + unsigned int n = strtoul(Char(value), &p, 0); + (void) n; if (errno || *p) { Clear(value); Append(value, "?");