mapfile.c: hashTableSubstituteString leaks memory #5325

Closed
gogglesguy opened this Issue Sep 14, 2016 · 5 comments

Projects

None yet

2 participants

@gogglesguy
Contributor

For the line:

msInsertHashTable(hash, key, msCaseReplaceSubstring(msStrdup(val), from, to));

The result of msCaseReplaceSubstring is never freed. HashTable stores a copy of it.

@tbonfort
Member

Can you create a pull request/patch for this please ?

@gogglesguy
Contributor
@tbonfort
Member

Perfect! If you want your name in the commit logs create a pr with that, if not i'll apply myself. Thanks.

@gogglesguy
Contributor

Just apply it!

@tbonfort tbonfort added a commit that referenced this issue Sep 15, 2016
@tbonfort tbonfort fix const on #5325 7c85787
@tbonfort
Member

applied to branch-7-0, thanks @gogglesguy

@tbonfort tbonfort closed this Sep 15, 2016
@tbonfort tbonfort added this to the 7.0.2 Release milestone Sep 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment