shared/main-func: also close the polkit agent automatically
The agent is closed after the static destuctors but before the pager. No users of DEFINE_MAIN_FUNCTION* were using a polkit agent, so this makes no functional difference.
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "pager.h"
|
||||
#include "spawn-polkit-agent.h"
|
||||
#include "static-destruct.h"
|
||||
|
||||
#define _DEFINE_MAIN_FUNCTION(impl, ret) \
|
||||
@@ -11,6 +12,7 @@
|
||||
int r; \
|
||||
r = impl(argc, argv); \
|
||||
static_destruct(); \
|
||||
polkit_agent_close(); \
|
||||
pager_close(); \
|
||||
return ret; \
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user