ORBit2 r2070 - in trunk: . src/orb/orb-core



Author: tml
Date: Wed Jun  4 00:18:06 2008
New Revision: 2070
URL: http://svn.gnome.org/viewvc/ORBit2?rev=2070&view=rev

Log:
2008-06-04  Tor Lillqvist  <tml novell com>

	Bug 536505 - Error building 2.14.13 - implicit declaration of
	function '_strnicmp'

	* src/orb/orb-core/orbhttp.c: Use g_ascii_strncasecmp() instead of
	strcasecmp() or _strnicmp(). _strnicmp() is Microsoft-specific and
	was introduced in this file by accident in the patch for bug
	524061 below. But actually, you shouldn't be using --enable-http.



Modified:
   trunk/ChangeLog
   trunk/src/orb/orb-core/orbhttp.c

Modified: trunk/src/orb/orb-core/orbhttp.c
==============================================================================
--- trunk/src/orb/orb-core/orbhttp.c	(original)
+++ trunk/src/orb/orb-core/orbhttp.c	Wed Jun  4 00:18:06 2008
@@ -57,10 +57,6 @@
 #  include <sys/select.h>
 #endif
 
-#if !defined(strncasecmp)
-#  define strncasecmp _strnicmp
-#endif
-
 #define CHECK_URI(str) \
 (!strncmp(str, "IOR:", strlen("IOR:")) \
  || !strncmp(str, "iiop://", strlen("iiop://")) \
@@ -515,13 +511,13 @@
 	}
 	if ((*cur != 0) && (*cur != ' ') && (*cur != '\t')) return;
 	ctxt->returnValue = ret;
-    } else if (!strncasecmp(line, "content-type:", 13)
-	       || !strncasecmp(line, "contenttype:", 12)) {
+    } else if (!g_ascii_strncasecmp(line, "content-type:", 13)
+	       || !g_ascii_strncasecmp(line, "contenttype:", 12)) {
         cur = strchr(cur, ':') + 1;
 	if (ctxt->contentType != NULL) return;
 	while ((*cur == ' ') || (*cur == '\t')) cur++;
 	ctxt->contentType = g_strdup(cur);
-    } else if (!strncasecmp(line, "Location:", 9)) {
+    } else if (!g_ascii_strncasecmp(line, "Location:", 9)) {
         cur += 9;
 	while ((*cur == ' ') || (*cur == '\t')) cur++;
 	if (ctxt->location != NULL)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]