Skip to content

Commit

Permalink
alloc_root_entry : check db pointer.
Browse files Browse the repository at this point in the history
  • Loading branch information
jfdelnero committed Nov 7, 2023
1 parent eb1a5de commit fae988f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/fs_handles_db.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,9 @@ fs_entry * alloc_root_entry(fs_handles_db * db, uint32_t storage_id)
{
fs_entry * entry;

if( !db )
return NULL;

entry = malloc(sizeof(fs_entry));
if( entry )
{
Expand Down

0 comments on commit fae988f

Please sign in to comment.