fix for possible out of bounds read, printing a warning with pointcache header.
This commit is contained in:
@@ -928,7 +928,7 @@ static int ptcache_dynamicpaint_read(PTCacheFile *pf, void *dp_v)
|
||||
/* version header */
|
||||
ptcache_file_read(pf, version, 1, sizeof(char) * 4);
|
||||
if (strncmp(version, DPAINT_CACHE_VERSION, 4)) {
|
||||
printf("Dynamic Paint: Invalid cache version: %s!\n", version);
|
||||
printf("Dynamic Paint: Invalid cache version: '%c%c%c%c'!\n", UNPACK4(version));
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user