diff --git a/Utils/OSWrapper.h b/Utils/OSWrapper.h index 74c978b..d3e1714 100755 --- a/Utils/OSWrapper.h +++ b/Utils/OSWrapper.h @@ -17,11 +17,11 @@ #include #include - typedef _chdir chdir; - typedef _getcwd getcwd; + #define _chdir chdir; + #define _getcwd getcwd; #ifdef _MSC_VER - typedef _access_s access; + #define _access_s access; #else #include #endif diff --git a/Utils/StringUtils.h b/Utils/StringUtils.h index 6b44618..2eef61b 100755 --- a/Utils/StringUtils.h +++ b/Utils/StringUtils.h @@ -47,7 +47,7 @@ namespace Utils size_t c = 0; while (*haystack && c < i + match * (newLength - oldLength)) { if (strstr(haystack, needle) == haystack) { - strcpy(&result[c], replace); + strcpy(&result[c], (char *) replace); c += newLength; haystack += oldLength; @@ -125,7 +125,7 @@ namespace Utils char *token; int i = 0; - while ((token = strsep(&str, &delim)) != NULL) { + while ((token = strsep(&str, (char *) & delim)) != NULL) { list[i] = (char *) malloc(strlen(token + 1) * sizeof(char)); memcpy(list[i], token, (strlen(token) + 1) * sizeof(char));