lib: Implement pthread_cancel via pthread_kill on Android
Android NDK does not provide pthread_cancel method, see discussion here, for example. This PR proposes simple workaround for this, initially proposed by @Hax4us. This change is fairly trivial so I don't expect any licensing or other issues. Official documentation of Android NDK states that correct implementation of pthread_cancel is too difficult, so we should consider to use something else on Android instead. Proper solution probably should use conditional variables.
Enter [N/A] in the box, if an item is not applicable to your change.
Testing Before we can approve your change; please submit the following in a comment:
- [N] Example configuration file for the change
- [N] Debug log output from testing the change
- [N] Attached Valgrind output that shows no leaks or memory corruption was found
If this is a change to packaging of containers or native binaries then please confirm it works for all targets.
- [N] Attached local packaging test output showing all targets (including any new ones) build.
Documentation
- [N] Documentation required for this feature
Backporting
- [N] Backport to latest stable release.
Fluent Bit is licensed under Apache 2.0, by submitting this pull request I understand that this code will be released under the terms of that license.
Failing tests under sanitizer don’t seem to be connected with this change, as behavior for platforms, another then Android, did not change at all.
This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.