Fixed small compatibility issues with win32 in codec (moved include <strings.h>)

This commit is contained in:
Francois-Olivier Devaux 2010-03-07 21:10:47 +00:00
parent 935baae8fc
commit 67b5ab3c04
3 changed files with 9 additions and 6 deletions

View File

@ -5,6 +5,9 @@ What's New for OpenJPEG
! : changed ! : changed
+ : added + : added
March 7, 2010
* [FOD] Fixed small compatibility issues with win32 in codec (moved include <strings.h>)
March 5,2010 March 5,2010
! [FOD] Updated makefiles for v1.4 and v2.0 ! [FOD] Updated makefiles for v1.4 and v2.0

View File

@ -43,8 +43,8 @@
#include "index.h" #include "index.h"
#ifndef WIN32 #ifndef WIN32
#define stricmp strcasecmp #define _stricmp strcasecmp
#define strnicmp strncasecmp #define _strnicmp strncasecmp
#endif #endif
/* ----------------------------------------------------------------------- */ /* ----------------------------------------------------------------------- */
@ -400,7 +400,7 @@ int get_file_format(char *filename) {
return -1; return -1;
ext++; ext++;
for(i = 0; i < sizeof(format)/sizeof(*format); i++) { 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]; return format[i];
} }
} }

View File

@ -43,8 +43,8 @@
#include "index.h" #include "index.h"
#ifndef WIN32 #ifndef WIN32
#define stricmp strcasecmp #define _stricmp strcasecmp
#define strnicmp strncasecmp #define _strnicmp strncasecmp
#endif #endif
/* ----------------------------------------------------------------------- */ /* ----------------------------------------------------------------------- */
@ -198,7 +198,7 @@ int get_file_format(char *filename) {
ext++; ext++;
if(ext) { if(ext) {
for(i = 0; i < sizeof(format)/sizeof(*format); i++) { 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]; return format[i];
} }
} }