mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Small style(9) improvements.
Approved by: dim (mentor)
This commit is contained in:
parent
9731596a5e
commit
4fb4550854
1 changed files with 4 additions and 2 deletions
|
|
@ -51,10 +51,12 @@ static struct quick_exit_handler *handlers;
|
|||
int
|
||||
at_quick_exit(void (*func)(void))
|
||||
{
|
||||
struct quick_exit_handler *h = malloc(sizeof(struct quick_exit_handler));
|
||||
struct quick_exit_handler *h;
|
||||
|
||||
h = malloc(sizeof(*h));
|
||||
|
||||
if (NULL == h)
|
||||
return 1;
|
||||
return (1);
|
||||
h->cleanup = func;
|
||||
pthread_mutex_lock(&atexit_mutex);
|
||||
h->next = handlers;
|
||||
|
|
|
|||
Loading…
Reference in a new issue