Fixed small compatibility issues with win32 in codec (moved include <strings.h>)
authorFrancois-Olivier Devaux <fodevaux@users.noreply.github.com>
Sun, 7 Mar 2010 21:10:47 +0000 (21:10 +0000)
committerFrancois-Olivier Devaux <fodevaux@users.noreply.github.com>
Sun, 7 Mar 2010 21:10:47 +0000 (21:10 +0000)
ChangeLog
codec/image_to_j2k.c
codec/j2k_to_image.c

index cd3448b61a5694b89db1e1e59c4c919a554e092f..87188c7d7b35674717824155354436a676f27e99 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,9 @@ What's New for OpenJPEG
 ! : changed
 + : added
 
+March 7, 2010
+* [FOD] Fixed small compatibility issues with win32 in codec (moved include <strings.h>)
+
 March 5,2010
 ! [FOD] Updated makefiles for v1.4 and v2.0
 
index 15621489a481aa19e0341a37b0ac375343883bf0..998d37824ebea028fe360434a015d5b286c3210a 100644 (file)
@@ -43,8 +43,8 @@
 #include "index.h"
 
 #ifndef WIN32
-#define stricmp strcasecmp
-#define strnicmp strncasecmp
+#define _stricmp strcasecmp
+#define _strnicmp strncasecmp
 #endif
 
 /* ----------------------------------------------------------------------- */
@@ -400,7 +400,7 @@ int get_file_format(char *filename) {
                return -1;
        ext++;
        for(i = 0; i < sizeof(format)/sizeof(*format); i++) {
-               if(strnicmp(ext, extension[i], 3) == 0) {
+               if(_strnicmp(ext, extension[i], 3) == 0) {
                        return format[i];
                }
        }
index 523cb5c4b9aa1275be747644ed63dd1879459457..c5b9120e3a91b7090ec06958ce256cb02960092e 100644 (file)
@@ -43,8 +43,8 @@
 #include "index.h"
 
 #ifndef WIN32
-#define stricmp strcasecmp
-#define strnicmp strncasecmp
+#define _stricmp strcasecmp
+#define _strnicmp strncasecmp
 #endif
 
 /* ----------------------------------------------------------------------- */
@@ -198,7 +198,7 @@ int get_file_format(char *filename) {
        ext++;
        if(ext) {
                for(i = 0; i < sizeof(format)/sizeof(*format); i++) {
-                       if(strnicmp(ext, extension[i], 3) == 0) {
+                       if(_strnicmp(ext, extension[i], 3) == 0) {
                                return format[i];
                        }
                }