Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory cleanups #9

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cfg_param.c
Original file line number Diff line number Diff line change
Expand Up @@ -1070,6 +1070,7 @@ void system_shutdown()
release_services();
release_modules();
ci_dlib_closeall();
release_body_system();

/*
Release other subsystems
Expand Down
1 change: 1 addition & 0 deletions service.c
Original file line number Diff line number Diff line change
Expand Up @@ -496,6 +496,7 @@ int release_services()
ci_list_destroy(service_extra_data_list[i].option_handlers);
service_extra_data_list[i].option_handlers = NULL;
}
free(service_data(service_list[i]));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is does not looks correct. The service_data function will return a pointer to an item of the service_extra_data_list array. This item is not an allocated memory block.

In the other hand the service_extra_data_list array needs to be released.

}
}

Expand Down