mirror of
https://github.com/facebook/zstd.git
synced 2025-08-01 09:47:01 +03:00
changed name from createX to assembleX
shows that the resulting object just takes ownership of provided buffer.
This commit is contained in:
@ -770,7 +770,7 @@ int main (int argc, const char** argv)
|
||||
|
||||
if (argc < 2) return bad_usage(exeName);
|
||||
|
||||
const char** nameTable = (const char**)malloc(argc * sizeof(const char*));
|
||||
const char** nameTable = (const char**)malloc((size_t)argc * sizeof(const char*));
|
||||
assert(nameTable != NULL);
|
||||
unsigned nameIdx = 0;
|
||||
|
||||
@ -805,7 +805,7 @@ int main (int argc, const char** argv)
|
||||
#endif
|
||||
filenameTable = UTIL_createExpandedFNT(nameTable, nameIdx, 1 /* follow_links */);
|
||||
} else {
|
||||
filenameTable = UTIL_createFileNamesTable(nameTable, nameIdx, NULL);
|
||||
filenameTable = UTIL_assembleFileNamesTable(nameTable, nameIdx, NULL);
|
||||
nameTable = NULL; /* UTIL_createFileNamesTable() takes ownership of nameTable */
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user