зеркало из
https://git.tukaani.org/xz.git
synced 2025-09-18 00:18:23 +00:00
Free the allocated memory in lzmadec if debugging is
enabled. This should make it possible to detect possible memory leaks with Valgrind.
Этот коммит содержится в:
родитель
8235e6e5b2
Коммит
01d71d60b7
@ -513,5 +513,12 @@ main(int argc, char **argv)
|
||||
} while (++optind < argc);
|
||||
}
|
||||
|
||||
#ifndef NDEBUG
|
||||
// Free the memory only when debugging. Freeing wastes some time,
|
||||
// but allows detecting possible memory leaks with Valgrind.
|
||||
lzma_end(&strm);
|
||||
lzma_memlimit_end(mem_limitter, false);
|
||||
#endif
|
||||
|
||||
return exit_status;
|
||||
}
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user