Commit Graph
4924 Commits
Author SHA1 Message Date
Evgeny Grin (Karlson2k) 50c9e5efea Added custom memory poisoning for MemoryPool 2021-10-10 21:16:25 +03:00
Evgeny Grin (Karlson2k) fe8a9c6181 configure: improved comment 2021-10-10 20:35:11 +03:00
Evgeny Grin (Karlson2k) abcbf77867 Partially reworked memory allocation from the pool
More robust implementation, should catch non-standard situations.
Always track read and write buffers, even if size is zero as
buffer pointers are used for data size calculations.
2021-10-10 20:28:07 +03:00
Evgeny Grin (Karlson2k) 899730e8c7 configure: fixed wrong brackets 2021-10-09 17:17:40 +03:00
Evgeny Grin (Karlson2k) 50067864c0 configure: removed "-fno-common" for sanitizers as it's not used by MHD 2021-10-06 11:46:24 +03:00
Evgeny Grin (Karlson2k) 6acc44c9c9 test_upgrade{,_large}.c: fixed portability 2021-10-06 11:30:43 +03:00
Evgeny Grin (Karlson2k) 1a17440608 Muted sanitizer errors on W32 platform.
Actually MinGW headers need to be fixed.
2021-10-06 11:30:42 +03:00
Evgeny Grin (Karlson2k) cc2d26ef3d configure: check whether leak detection is supported
Leak detection is not supported on some platforms. Added check to avoid
having all tests failing on such platforms.
2021-10-06 11:30:23 +03:00
Evgeny Grin (Karlson2k) 5e3862d628 internal.h: fixed typo in comment, updated copyright 2021-10-05 17:17:09 +03:00
Evgeny Grin (Karlson2k) 85db559ed6 Added support for "noreturn" function declaration.
It should help static analyzer to properly detect code paths.
2021-10-04 10:32:11 +03:00
Evgeny Grin (Karlson2k) 22aff9e263 .gitignore: ignore new tests files 2021-10-03 21:28:18 +03:00
Evgeny Grin (Karlson2k) 5f86e35b56 test_toolarge: fixed possible NULL dereference with possible test extension 2021-10-03 21:24:55 +03:00
Evgeny Grin (Karlson2k) 33ce983bb6 transmit_error_response(): use last resort to send error response 2021-10-03 21:22:27 +03:00
Evgeny Grin (Karlson2k) 16f6b9460c connection_alloc_memory(): fixed missing update of buffers sizes 2021-10-03 21:08:01 +03:00
Evgeny Grin (Karlson2k) 3d10823017 process_broken_line(): avoid double error sending 2021-10-03 20:59:16 +03:00
Evgeny Grin (Karlson2k) 0fd78e5f40 build_header_response(): fail early if no write space is available 2021-10-03 20:50:46 +03:00
Evgeny Grin (Karlson2k) 9d6c3deddb test_toolarge: fixed leak of the test memory allocation 2021-10-03 20:43:20 +03:00
Evgeny Grin (Karlson2k) 499de9db0c test_toolarge: clarified file doxy description 2021-10-03 20:17:00 +03:00
Evgeny Grin (Karlson2k) 4be55403c1 Added set of test test_toolarge
Added a set of tests for checking of possible buffer overflow / overrun
but using range of sizes for request and response elements starting
for valid ranges.
Tests are designed with thorough and detailed checking of all
parameters provided and detected by MHD.
2021-10-03 20:07:28 +03:00
Evgeny Grin (Karlson2k) d7cac57883 connection_maximize_write_buffer(): don't try to grow if no space is available 2021-09-29 20:48:53 +03:00
Evgeny Grin (Karlson2k) 0eb370643d transmit_error_response(): reset read buffer offset as well 2021-09-29 20:45:41 +03:00
Evgeny Grin (Karlson2k) ac72beaa2b transmit_error_response(): improved error log messages 2021-09-29 20:45:26 +03:00
Evgeny Grin (Karlson2k) f7c1213806 transmit_error_response(): log error if response cannot be created 2021-09-29 20:45:14 +03:00
Evgeny Grin (Karlson2k) 85afdbaf90 transmit_error_response(): check whether it is still possible to send a response 2021-09-29 20:44:56 +03:00
Evgeny Grin (Karlson2k) ccd75de5b8 connection_reset(): notify app with correct code 2021-09-29 20:44:24 +03:00
Evgeny Grin (Karlson2k) cb5332ab43 transmit_error_response(): avoid double sending of error responses 2021-09-29 20:44:14 +03:00
Evgeny Grin (Karlson2k) 4e01fd656a connection_close_error(): fixed set of error flag with messages disabled 2021-09-29 20:43:14 +03:00
Evgeny Grin (Karlson2k) 7278e5818e memorypool: added assert in MHD_pool_reallocate() 2021-09-29 20:42:55 +03:00
Evgeny Grin (Karlson2k) 235a277df3 connection.c: fixed compile with disabled messages 2021-09-29 20:42:37 +03:00
Evgeny Grin (Karlson2k) c07f446418 microhttpd.h: fixed doxy for MHD_KeyValueIteratorN 2021-09-28 21:06:39 +03:00
Evgeny Grin (Karlson2k) 9ba991c7d9 Improved and fixed doxy for MHD_add_response_header() 2021-09-26 18:34:59 +03:00
Evgeny Grin (Karlson2k) 71e09c24e6 Clarified doxy description of MHD_run_wait() 2021-09-25 19:45:44 +03:00
Evgeny Grin (Karlson2k) cba8e9f23e tests: fixed case-insensitive match for method name 2021-09-22 21:03:22 +03:00
Evgeny Grin (Karlson2k) 2c4af5c590 test_postprocessor: changed to match current API 2021-09-20 11:28:20 +03:00
Evgeny Grin (Karlson2k) fd609acd9e Partial revert "postprocessor: use NULL for 'data' for callback if no value is present"
This reverts commit 1e314fd50a.

The API change postponed until the next MHD version
2021-09-19 18:33:59 +03:00
Evgeny Grin (Karlson2k) d964b3ef85 postprocessor: added new processing state, changed logic.
Changed code to ensure that PP_Done is always set at the first newline char.
2021-09-19 16:06:03 +03:00
Evgeny Grin (Karlson2k) 215d156551 postprocessor: removed unused state value 2021-09-19 15:16:27 +03:00
Evgeny Grin (Karlson2k) 685e6368f4 postprocessor: simplify processing of urlencoding in edge cases 2021-09-17 12:19:03 +03:00
Evgeny Grin (Karlson2k) cc1d7c61ae configure: added detection of used run-time lib (type of C lib) 2021-09-17 11:58:55 +03:00
Evgeny Grin (Karlson2k) acc4cc29ed Cosmetics: fixed formatting for 'examples' 2021-09-17 11:54:58 +03:00
Evgeny Grin (Karlson2k) bf1993237a Use type specifiers for printf() from inttypes.h
This should improve compatibility with various C libs.
2021-09-17 11:53:55 +03:00
Christian Grothoff bd3325c924 -fix typo 2021-09-16 17:53:25 +02:00
Evgeny Grin (Karlson2k) 468723c2f6 ax_pthread.m4: updated to the latest version 2021-09-15 21:59:31 +03:00
Evgeny Grin (Karlson2k) e9096b7c8d postprocessor: fixed incomplete processing of hex-encoding values
Under certain conditions, the final part of the last value can be left
unprocessed.
2021-09-15 21:43:51 +03:00
Evgeny Grin (Karlson2k) 495da1140e test_postprocessor: added testing of hex-encoded values 2021-09-15 21:18:33 +03:00
Evgeny Grin (Karlson2k) 0d467e4c75 test_postprocessor: report more details 2021-09-15 21:16:46 +03:00
Evgeny Grin (Karlson2k) ddcc20a0ba postprocessor: minor code improvement 2021-09-15 19:54:46 +03:00
Evgeny Grin (Karlson2k) 1cf2ccde32 test_postprocessor: added test with double value 2021-09-15 19:47:17 +03:00
Evgeny Grin (Karlson2k) e3ed5e0d17 test_postprocessor: improved error reporting 2021-09-15 19:10:42 +03:00
Evgeny Grin (Karlson2k) 6dd2096b4b Fixed f032145edc
Ensure that parsing fail because of the wrong format, not
because of the callback.
2021-09-15 17:37:58 +03:00