Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP4:Update
pacemaker.13252
pacemaker-libcrmcommon-avoid-memory-leak-when-s...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File pacemaker-libcrmcommon-avoid-memory-leak-when-schema-transform-not-found.patch of Package pacemaker.13252
commit d2c2bf04693899dcfe79be024faf72f02adfb419 Author: Ken Gaillot <kgaillot@redhat.com> Date: Fri Mar 2 09:48:28 2018 -0600 Low: libcrmcommon: avoid memory leak when schema transform not found Index: pacemaker-1.1.18+20180126.bfe4e8042/lib/common/schemas.c =================================================================== --- pacemaker-1.1.18+20180126.bfe4e8042.orig/lib/common/schemas.c +++ pacemaker-1.1.18+20180126.bfe4e8042/lib/common/schemas.c @@ -301,7 +301,6 @@ crm_schema_init(void) // Shouldn't be possible, but makes static analysis happy crm_err("Skipping schema '%s': could not parse version", namelist[lpc]->d_name); - free(namelist[lpc]); continue; } if ((lpc + 1) < max) { @@ -331,9 +330,13 @@ crm_schema_init(void) } add_schema(schema_validator_rng, &version, NULL, NULL, transform, next); - free(namelist[lpc]); free(transform); } + + for (lpc = 0; lpc < max; lpc++) { + free(namelist[lpc]); + } + free(namelist); } /* 1.1 was the old name for -next */ @@ -345,7 +348,6 @@ crm_schema_init(void) add_schema(schema_validator_none, &zero, "none", "N/A", NULL, -1); - free(namelist); } static gboolean
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor