summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Create test tag.1.7.1-test1ivan2023-01-210-0/+0
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.1-test1@1906868 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906864 from trunk:ivan2023-01-213-0/+3
| | | | | | .github/workflows: Enable CI builds for tags. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906866 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906826 from 1.8.x:covener2023-01-191-0/+4
| | | | | | | | | | | | | | | Merge r1906825 from trunk: force USE_SHMEM_SHMGET on AIX prior to r1901037 on trunk, USE_SHMEM_SHMGET is used. APR_USE_SHMEM_MMAP_SHM does not currently work on AIX. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906827 13f79535-47bb-0310-9956-ffa450edef68
* prep to tag 1.7.1covener2023-01-191-1/+1
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906812 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906809 from trunk:covener2023-01-192-2/+2
| | | | | | | | bump copyright for 2023 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906811 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906751 from 1.8.x:ivan2023-01-171-2/+4
| | | | | | | | | CMakeLists.txt: Make CMAKE_MINIMUM_REQUIRED first directive as recommended by CMake documentation [1]. [1] https://cmake.org/cmake/help/latest/command/cmake_minimum_required.html git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906752 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906723 from trunk:jorton2023-01-172-2/+2
| | | | | | | | | | | | | | Further strict C99 configure fix: Avoid an implicit int in the definition of the main function. Avoids build problems with future C compilers which will not support them by default. Submitted by: Florian Weimer <fweimer redhat.com> PR: 66426 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906725 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906594 from trunk:jorton2023-01-115-7/+31
| | | | | | | | | | Fix further strict C99 compliance issue. (fixes #37) PR: 66408 Submitted by: Sam James <sam gentoo.org> git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906595 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1906347 from trunk:jorton2023-01-032-1/+4
| | | | | | | | | | | Fix configure for compilers which don't accept implicit int (no longer part of C since C99). Submitted by: Florian Weimer <fweimer redhat.com> PR: 66396 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1906349 13f79535-47bb-0310-9956-ffa450edef68
* testfile: try to determine how apr_file_datasync() fails for streams on macos.ylavic2022-10-201-1/+7
| | | | | | | | | | | | | | | | | | * test/testfile.c(test_datasync_on_stream): Let ABTS_INT_EQUAL show the actual errno. test/testfile.c: apr_file_datasync() fails with ENOTSUP for streams on macos. * test/testfile.c(test_datasync_on_stream): Handle ENOTSUP on macos. Merge r1902175, r1902180 from trunk. Merges r1902228 from ^/apr/apr/branches/1.8.x. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904747 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1904735 from 1.8.x branch:kotkov2022-10-201-7/+2
| | | | | | | | Following up on r1904715, rework the check to properly handle an overflow when apr_size_t is 32-bit long. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904736 13f79535-47bb-0310-9956-ffa450edef68
* Trigger ciylavic2022-10-201-1/+1
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904725 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1904716 from 1.8.x branch:kotkov2022-10-201-32/+22
| | | | | | | | | Win32: Stop apr_socket_sendv() from splitting iovecs into multiple possible WSABUFs and error out on theoretical cases that cannot be handled with a single WSASend(). git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904718 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Revert r1904674 that merged r1902312 from trunkkotkov2022-10-201-21/+12
| | | | | | | (apr_socket_sendv: WIN32: Limit the number of WSABUFs allocated for a single call). git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904717 13f79535-47bb-0310-9956-ffa450edef68
* encoding: Better check inputs of apr_{encode,decode}_* functions.ylavic2022-10-185-806/+1224
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check that the given sources can be encoded without overflowing. Return APR_EINVAL if the given "slen" is negative, APR_NOTFOUND if "dest" is not NULL and "src" is NULL, or APR_ENOSPC if "dest" is NULL and the source length (based on "slen" or APR_ENCODE_STRING) is too big to encode. * include/private/apr_encode_private.h(): Rename ENCODE_TO_ASCII() and ENCODE_TO_NATIVE() to respectively TO_ASCII() and TO_ENCODE(), and make them return an unsigned char. * encoding/apr_escape.c(): Use the new TO_ASCII() and TO_NATIVE(). * encoding/apr_encode.c(apr_encode_*, apr_decode_*): Forbid negative "slen" but APR_ENCODE_STRING, and use apr_size_t arithmetics to check for overflows when encoding. When "dest" is NULL, "src" can be NULL too. Better check for trailing '='s or base16's APR_ENCODE_COLON ':' separators. Rename ENCODE_TO_ASCII and ENCODE_TO_NATIVE to their new names, and remove casts to (unsigned char) now unnecessary. * include/apr_encode.h(): Update dox about acceptable inputs and returned errors. * test/testencode.c(): Tests for error conditions. testencode: Follow up to r1902281: error tests for apr_decode_base16_binary. testencode: Follow up to r1902281: Correct call convention for encdec_fn. testencode: Follow up to r1902281: Correct call convention for encdec_fn (try 2). testencode: Follow up to r1902281: Inline, no calling convention assumptions. Merges r1902281, r1902282, r1902284, r1902285, r1902286 from trunk. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904675 13f79535-47bb-0310-9956-ffa450edef68
* apr_socket_sendv: WIN32: Limit the number of WSABUFs allocated for a single ↵ylavic2022-10-181-12/+21
| | | | | | | | | | | | | | | | | call. * network_io/win32/sendrecv.c(): Define WSABUF_ON_HEAP to 500. * network_io/win32/sendrecv.c(apr_socket_sendv): Do not sendv more than WSABUF_ON_HEAP WSABUFs. Merge r1902312 from trunk. [Reverted by r1904717] git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904674 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x: Merge r1902043 from 1.8.x branch:ivan2022-09-122-9/+8
| | | | | | | Fix a regression in apr_stat() for root path on Windows caused by the extended symlink detection added in r1855949 (PR47630). git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904030 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x: Merge r1902119, r1902122, r1902223 from 1.8.x branch:ivan2022-09-121-0/+94
| | | | | | | - Add simple tests for nested and unnested thread mutexes. - Add test for WAIT_ABANDONED handling for win32 mutexes. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904029 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1902111 from 1.8.x branch:ivan2022-09-122-2/+6
| | | | | | win32: Fix double free on exit when apr_app is used on Windows. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904025 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1902110 from 1.8.x branch:ivan2022-09-122-5/+30
| | | | | | win32: Fix attempt to free invalid memory on exit when apr_app is used. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904024 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1902116, r1902254, r1902219 from 1.8.x branch:ivan2022-09-121-4/+54
| | | | | | Lock tests fixes. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904023 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1902088 from 1.8.x branch:ivan2022-09-121-2/+2
| | | | | | Merge r1895514 and r1902063 from trunk. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904017 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1904015 from 1.8.x branch:ivan2022-09-121-0/+17
| | | | | | | tests: Configure VC runtime to write errors to stderr instead of displaying popup message box on Windows. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904016 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge following revisions from 1.8.x branch:ivan2022-09-121-49/+61
| | | | | | | | | * r1902090: CMakeLists.txt: Pass '-v' to testall.exe when running tests. * r1902089: CMakeLists.txt: Set BINPATH for test executables. * r1902041: CMakeLists: Make testall test suites separate tests in terms of CMake/CTest. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904014 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1901906 and r1901907 from 1.8.x branch.ivan2022-09-121-0/+3
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904013 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch: Merge r1902578 from 1.8.x branch:ivan2022-09-121-0/+4
| | | | | | win32: Fix build with IPv6 disabled. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904012 13f79535-47bb-0310-9956-ffa450edef68
* On 1.7.x branch:ivan2022-09-123-0/+133
| | | | | | | | Merge r1902092, r1902096, r1902139, r1902140, r1902141, r1902143, r1902146, r1902164, r1902166, r1902226, r1902295 from trunk: GitHub Actions configuration. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1904011 13f79535-47bb-0310-9956-ffa450edef68
* Revert r1887508 and r1887497.ylavic2022-06-305-134/+35
| | | | | | | | Per https://lists.apache.org/thread/jt7by9hhvsnpo5ztjmbq5rrpnq2n0b8v git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902372 13f79535-47bb-0310-9956-ffa450edef68
* Revert r1897210, r1897211 and r1884103.ylavic2022-06-309-276/+99
| | | | | | | | Per https://lists.apache.org/thread/w0wmkpngyffv8t5r22xvt3romxn41ycw git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902369 13f79535-47bb-0310-9956-ffa450edef68
* atomic: Detect 32bit and 64bit atomic builtins separately.ylavic2022-06-273-9/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some 32bit platforms provide 32bit but not 64bit atomics, detect and distinctly set/use HAVE_ATOMIC_BUILTINS/HAVE_ATOMIC_BUILTINS64 and USE_ATOMICS_BUILTINS/USE_ATOMICS_BUILTINS64. These platforms NEED_ATOMICS_GENERIC64 as 64bit implementation. * configure.in(): Use stdint.h's uint{32,64}_t as atomic type for testing atomic builtins when available, otherwise "unsigned int" for 32bit testing and "unsigned long long" as 64bit. * configure.in(): AC_TRY_RUN each 32bit and 64bit type separately, the former determining HAVE_ATOMIC_BUILTINS and the latter HAVE_ATOMIC_BUILTINS64. * include/arch/unix/apr_arch_atomic.h(): Define USE_ATOMICS_BUILTINS64 when HAVE_ATOMIC_BUILTINS64, otherise define NEED_ATOMICS_GENERIC64 * include/arch/unix/apr_arch_atomic.h(): Check defined(__powerpc__) for USE_ATOMICS_PPC. * atomic/unix/builtins64.c(): Implement for USE_ATOMICS_BUILTINS64 only. BZ 63566. Merge r1902266 from trunk. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902290 13f79535-47bb-0310-9956-ffa450edef68
* time: Don't apr_sleep() less than the requested time on WIN32.ylavic2022-06-241-1/+1
| | | | | | | | | | | | | | | Windows' Sleep() has millisecond granularity while the given apr_time_t to sleep is in microseconds, so round up. * time/win32/time.c(apr_sleep): Round up given time to upper milliseconds. Merge r1902169 from trunk. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902235 13f79535-47bb-0310-9956-ffa450edef68
* No autoconf substitution with cmake for APR_TCP_NOPUSH_FLAG.ylavic2022-06-171-1/+1
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902025 13f79535-47bb-0310-9956-ffa450edef68
* Revert r1897209 and r1863234 to preserve ABI on 1.7.x.ylavic2022-06-172-11/+8
| | | | | | Per https://lists.apache.org/thread/wkz9snh2551wrqfj0g0f7om442ncnbyq git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902022 13f79535-47bb-0310-9956-ffa450edef68
* Fix various harmless cases of undefined behaviour, and add a Travisylavic2022-06-175-8/+20
| | | | | | | | | | | | | | | | | | | | | | job testing under UBSan. * poll/unix/poll.c (apr_poll): For the on-stack array allocation use num+1 since allocating a 0-length array is undefined behaviour. * tables/apr_skiplist.c (get_b_rand): Use unsigned integers to avoid signed integer overflow in the left shift. (skiplist_qpush): Avoid calling memcpy(,NULL,0). * random/unix/apr_random.c (apr_random_add_entropy): Avoid calling memcpy(,NULL,0). * test/teststr.c (overflow_strfsize): Avoid signed integer overflow. Merge r1898076 from trunk. Submitted by: jorton git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1902021 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1901037 from trunk:jim2022-05-182-5/+8
| | | | | | | | | | Prefer posix shared mem over SysV in all cases: Have name based order same as anon Reviewed by: jim git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1901038 13f79535-47bb-0310-9956-ffa450edef68
* Fix apr.hw input file, tcp_nopush absent on Windowswrowe2022-03-092-6/+1
| | | | | | Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1898799 13f79535-47bb-0310-9956-ffa450edef68
* Bump (C)wrowe2022-03-092-2/+2
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1898795 13f79535-47bb-0310-9956-ffa450edef68
* Revert r1896510.ylavic2022-01-1914-151/+96
| | | | | | | | Per https://lists.apache.org/thread/rt6ggcztj7w1vwrmhz27q5fz27pr57w9 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897222 13f79535-47bb-0310-9956-ffa450edef68
* apr_thread: Follow up to r1897210: 1.7.x has a _WIN32_WCE error path too.ylavic2022-01-191-1/+3
| | | | | | | | | | Destroy the pool if Windows' apr_thread_crate() fails on _WIN32_WCE, the merge in r1897210 applied its changes to the other case (known to trunk) only. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897211 13f79535-47bb-0310-9956-ffa450edef68
* apr_thread: Follow up to r1884078: Unmanaged pools for attached threads too.ylavic2022-01-196-264/+155
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | [Note 1.7.x: this removes apr__pool_unmanage() thus r1884103's ABI issues] r1884078 fixed lifetime issues with detached threads by using unmanaged pool destroyed by the thread itself on exit, with no binding to the parent pool. This commit makes use of unmanaged pools for attached threads too, they needed their own allocator anyway due to apr_thread_detach() being callable anytime later. apr__pool_unmanage() was a hack to detach a subpool from its parent, but if a subpool needs its own allocator for this to work correctly there is no point in creating a subpool for threads (no memory reuse on destroy for short living threads for instance). Since an attached thread has its own lifetime now, apr_thread_join() must be called to free its resources/pool, though it's no different than before when destroying the parent pool was UB if the thread was still running (i.e. not joined yet). Let's acknoledge that threads want no binding with the pool passed to them at creation time, besides the abort_fn which they can steal :) Merges r1897179 from trunk. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897210 13f79535-47bb-0310-9956-ffa450edef68
* apr_pools: Follow up to r1863234: APR_POOL_DEBUG macros for compat.ylavic2022-01-192-26/+19
| | | | | | | | | To preserve ABI, define apr_pool_{join,find,num_bytes,lock}() as no-op macros in 1.7.x. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897209 13f79535-47bb-0310-9956-ffa450edef68
* Note 1.8.x wrowe2022-01-141-1/+3
| | | | git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897023 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1893202 from trunk:ylavic2022-01-133-5/+21
| | | | | | | | | | | test: fix memory leaks of the test framework at exit. To please memory leak analysers.. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1897005 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1896971, r1896990, r1896992 from trunk:ylavic2022-01-131-4/+35
| | | | | | | | | | | Add Asan builds to travis. Disable odbc tests with ASan for now, dlclose() leaks memory somehow. Move misplaced comment. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896996 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1896722, r1896782 from trunk:jorton2022-01-121-2/+12
| | | | | | | | | | Add GCC 10 build to Travis config. Since bionic is the default, switch one -Werror build to xenial. git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896966 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1896803 from trunk:ylavic2022-01-121-9/+9
| | | | | | | | | | | | | testatomic: Fix gcc-11 warnings. Not sure why it wants the "a" local variable to point to something since we only use its pointer, but that's how it is.. While at it let's initialize "b" too. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896962 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1896811 from trunk:ylavic2022-01-121-0/+7
| | | | | | | | | | | apr_atomic_set64: Follow up to r1868129. Like for apr_atomic_read64() in r1868502, use direct memory write on x86_x64. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896960 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1896956 from trunk:ylavic2022-01-121-3/+4
| | | | | | | | | | | apr_sockaddr_ip_getbuf: Follow up to r1883728. Return APR_ENOSPC if returned buf is truncated for an AF_UNIX. Submitted by: ylavic git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896958 13f79535-47bb-0310-9956-ffa450edef68
* Revert VPATH build breakage introduced in r1890192wrowe2022-01-121-2/+2
| | | | | | | | | | | | | | Avoids the scenario; gcc tools/gen_test_char.c -o tools/gen_test_char gcc: error: tools/gen_test_char.c: No such file or directory gcc: fatal error: no input files Substitute the source tree path to this file rather that the target tree. Backports: r1896933 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896934 13f79535-47bb-0310-9956-ffa450edef68
* Merge r1895178 from trunk:ylavic2022-01-071-1/+1
| | | | | | | | | Fix typo Submitted by: mturk git-svn-id: https://svn.apache.org/repos/asf/apr/apr/branches/1.7.x@1896808 13f79535-47bb-0310-9956-ffa450edef68