Skip to content

Commit

Permalink
db_sqlite: drop pkg_free() NULL check
Browse files Browse the repository at this point in the history
Thanks go to Liviu Chircu for better readability suggestions
  • Loading branch information
razvancrainea committed Nov 2, 2021
1 parent ce8d82b commit c7ec9e1
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions modules/db_sqlite/dbase.c
Expand Up @@ -842,11 +842,7 @@ static void db_sqlite_free_result_rows(db_res_t* _r)
/* db_sqlite_allocate_rows allocates memory for rows and values separately.
* Hence freeing rows using generic function and then values separately*/
db_free_rows(_r);
if(values)
{
pkg_free(values);
values = NULL;
}
pkg_free(values);
}
RES_ROWS(_r) = 0;
RES_ROW_N(_r) = 0;
Expand Down

0 comments on commit c7ec9e1

Please sign in to comment.