rouault commented on pull request #44:
URL: https://github.com/apache/xerces-c/pull/44#issuecomment-986261189


   I've updated the commit with the above strategy I mentioned in 
https://github.com/apache/xerces-c/pull/44#discussion_r762457868. The diff 
might be hard to read because of the indentation changes, but the changes 
themselves are relatively simple and consist in:
   - moving 
https://github.com/apache/xerces-c/blob/8ac9637b4a54e0b0a52e59b0299aaa974e8fc453/src/xercesc/validators/common/DFAContentModel.cpp#L1006
 to 
https://github.com/apache/xerces-c/blob/8ac9637b4a54e0b0a52e59b0299aaa974e8fc453/src/xercesc/validators/common/DFAContentModel.cpp#L1264
 of one indentation level in a try {} block
   - moving 
https://github.com/apache/xerces-c/blob/8ac9637b4a54e0b0a52e59b0299aaa974e8fc453/src/xercesc/validators/common/DFAContentModel.cpp#L1266
 to 
https://github.com/apache/xerces-c/blob/8ac9637b4a54e0b0a52e59b0299aaa974e8fc453/src/xercesc/validators/common/DFAContentModel.cpp#L1329
 in the finalizeProcessingAndCleanup() lambda
   - calling that lambda after the try {} block in the nominal case, and in the 
catch ( OutOfMemoryException ) block
   - and doing the memory allocations 
https://github.com/apache/xerces-c/blob/master/src/xercesc/validators/common/DFAContentModel.cpp#L1228
 to 
https://github.com/apache/xerces-c/blob/8ac9637b4a54e0b0a52e59b0299aaa974e8fc453/src/xercesc/validators/common/DFAContentModel.cpp#L1249
 in a inner try {} catch (OutOfMemoryException) block, to do specific cleanups 
of those temporary arrays in case an exception is thrown


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org

Reply via email to