mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
updated for version 7.3.159
Problem: Using uninitialized pointer when out of memory. Solution: Check for NULL return value.
This commit is contained in:
@@ -4129,7 +4129,7 @@ iconv_string(vcp, str, slen, unconvlenp, resultlenp)
|
||||
done = to - (char *)result;
|
||||
}
|
||||
|
||||
if (resultlenp != NULL)
|
||||
if (resultlenp != NULL && result != NULL)
|
||||
*resultlenp = (int)(to - (char *)result);
|
||||
return result;
|
||||
}
|
||||
|
Reference in New Issue
Block a user