mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-22 05:48:01 +01:00
WMaker: fix memory leak when respawning after crash (Coverity #50165)
As pointed by Coverity, the memory allocated to contain the argument list for spawning ourself was never released. Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
committed by
Carlos R. Mafra
parent
659519f306
commit
4501d4c078
@@ -125,6 +125,7 @@ int MonitorLoop(int argc, char **argv)
|
|||||||
* the crash panel and ask the user what to do */
|
* the crash panel and ask the user what to do */
|
||||||
if (time(NULL) - last_start < 3) {
|
if (time(NULL) - last_start < 3) {
|
||||||
if (showCrashDialog(WTERMSIG(status)) == 0) {
|
if (showCrashDialog(WTERMSIG(status)) == 0) {
|
||||||
|
wfree(child_argv);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -133,5 +134,6 @@ int MonitorLoop(int argc, char **argv)
|
|||||||
} else
|
} else
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
wfree(child_argv);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user