mirror of
https://github.com/libretro/RetroArch
synced 2024-07-05 09:48:42 +00:00
(libretro-db/query.c) Prevent warning 'use-after-free'
This commit is contained in:
parent
97df8ce2fa
commit
1c1cac328d
|
@ -1008,12 +1008,13 @@ void *libretrodb_query_compile(libretrodb_t *db,
|
|||
libretrodb_query_free(q);
|
||||
return NULL;
|
||||
}
|
||||
goto success;
|
||||
|
||||
return q;
|
||||
|
||||
clean:
|
||||
if (q)
|
||||
libretrodb_query_free(q);
|
||||
success:
|
||||
return q;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void libretrodb_query_inc_ref(libretrodb_query_t *q)
|
||||
|
|
Loading…
Reference in New Issue
Block a user