File tree 2 files changed +17
-0
lines changed
2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change 1
1
DD mmm YYYY - 2.9.x (to be released)
2
2
-------------------
3
3
4
+ * Fix memory leak in streams
5
+ [Issue #2208 @marcstern, @vloup, @JamesColeman-LW]
4
6
* Fix memory leak that occurs on JSON parsing error
5
7
[Issue #2236 @argenet, @vloup, @martinhsv]
6
8
* Multipart names/filenames may include single quote if double-quote enclosed
Original file line number Diff line number Diff line change @@ -325,6 +325,21 @@ static apr_status_t modsecurity_tx_cleanup(void *data) {
325
325
#endif
326
326
#endif
327
327
328
+ /* Streams cleanup. */
329
+ if (msr -> stream_input_data != NULL ) {
330
+ free (msr -> stream_input_data );
331
+ msr -> stream_input_data = NULL ;
332
+ msr -> stream_input_length = 0 ;
333
+ #ifdef MSC_LARGE_STREAM_INPUT
334
+ msr -> stream_input_allocated_length = 0 ;
335
+ #endif
336
+ }
337
+ if (msr -> stream_output_data != NULL ) {
338
+ free (msr -> stream_output_data );
339
+ msr -> stream_output_data = NULL ;
340
+ msr -> stream_output_length = 0 ;
341
+ }
342
+
328
343
return APR_SUCCESS ;
329
344
}
330
345
You can’t perform that action at this time.
0 commit comments