GNOME Bugzilla – Bug 711149
dangling handlers in encoding.c
Last modified: 2013-11-29 15:14:37 UTC
Created attachment 258573 [details] [review] Fixing dangling handlers. In File : https://git.gnome.org/browse/libxml2/tree/encoding.c In Function: int xmlCharEncCloseFunc(xmlCharEncodingHandler *handler) If the freed handler is any one of handlers[i] list, then it will make that hanldlers[i] as dangling. This may lead to crash issues at places where handlers is read. The attached patch is fix for this situation.
That scenario is unlikely unless someone registers encoders twice, but I'm fine fixing this. I had to clean up significantly the patch as I from the loop was not declared, and we don't use bool type in libxml2. But i pushed the result, https://git.gnome.org/browse/libxml2/commit/?id=080a22c5ea395adede98d555d2dab2c85b16b269 thanks, Daniel