mirror of
https://github.com/Motion-Project/motion.git
synced 2026-04-20 05:56:58 -04:00
Revise free process to close leaks
This commit is contained in:
@@ -82,7 +82,10 @@ void dbse_global_deinit(struct ctx_motapp *motapp)
|
||||
|
||||
indx = 0;
|
||||
while (motapp->cam_list[indx] != NULL) {
|
||||
util_free_var(motapp->cam_list[indx]->dbse);
|
||||
if (motapp->cam_list[indx]->dbse != NULL) {
|
||||
free(motapp->cam_list[indx]->dbse);
|
||||
}
|
||||
motapp->cam_list[indx]->dbse = NULL;
|
||||
indx++;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user