mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-30 15:18:42 +02:00
A null pointer check
This commit is contained in:
parent
58e3f3da83
commit
3410b601e1
@ -261,7 +261,8 @@ bool ExportFFmpeg::Init(const char *shortname, AudacityProject *project, const T
|
||||
{
|
||||
// This will undo the acquisition of resources along any early exit path:
|
||||
auto deleter = [](ExportFFmpeg *This) {
|
||||
This->FreeResources();
|
||||
if (This)
|
||||
This->FreeResources();
|
||||
};
|
||||
std::unique_ptr<ExportFFmpeg, decltype(deleter)> cleanup{ this, deleter };
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user