fix for building with mingw

This commit is contained in:
Campbell Barton
2013-05-13 05:40:51 +00:00
parent 8576a275dc
commit 28ecc1ce20
2 changed files with 3 additions and 3 deletions

View File

@@ -253,7 +253,7 @@ void *BLI_gzopen(const char *filename, const char *mode)
/* temporary #if until we update all libraries to 1.2.7
* for correct wide char path handling */
#if ZLIB_VERNUM >= 0x1270
#if ZLIB_VERNUM >= 0x1270 && !defined(FREE_WINDOWS)
UTF16_ENCODE(filename);
gzfile = gzopen_w(filename_16, mode);

View File

@@ -118,8 +118,8 @@ int BLI_str_cursor_step_next_utf8(const char *str, size_t maxlen, int *pos)
const char *str_next = BLI_str_find_next_char_utf8(str_pos, str_end);
if (str_next) {
(*pos) += (str_next - str_pos);
if ((*pos) > maxlen) {
(*pos) = maxlen;
if ((*pos) > (int)maxlen) {
(*pos) = (int)maxlen;
}
return TRUE;
}