aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2023-08-22 17:28:22 +0000
committerGitHub <noreply@github.com>2023-08-22 17:28:22 +0000
commite2026f7b71752c9b0bbba7438e2c62f2a4bca7f0 (patch)
tree454e220dae35bd009710ef75a7ec77b44520b935
parent959b75358971c41956346636ce84d46dbe1bf286 (diff)
parent71f9999f292ba524a4c67a124c00db4205111350 (diff)
downloadafl++-e2026f7b71752c9b0bbba7438e2c62f2a4bca7f0.tar.gz
Merge pull request #1840 from smoelius/stable
update afl-system-config for macos
-rwxr-xr-xafl-system-config6
-rw-r--r--src/afl-fuzz-init.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/afl-system-config b/afl-system-config
index b50bb06e..e64857eb 100755
--- a/afl-system-config
+++ b/afl-system-config
@@ -110,12 +110,12 @@ if [ "$PLATFORM" = "Darwin" ] ; then
sysctl kern.sysv.shmall=131072000
echo Settings applied.
echo
- if $(launchctl list 2>/dev/null | grep -q '\.ReportCrash$') ; then
+ if $(launchctl list 2>/dev/null | grep -q '\.ReportCrash\>') ; then
echo
echo Unloading the default crash reporter
SL=/System/Library; PL=com.apple.ReportCrash
- launchctl unload -w ${SL}/LaunchAgents/${PL}.plist >/dev/null 2>&1
- sudo launchctl unload -w ${SL}/LaunchDaemons/${PL}.Root.plist >/dev/null 2>&1
+ sudo -u "$SUDO_USER" launchctl unload -w ${SL}/LaunchAgents/${PL}.plist
+ launchctl unload -w ${SL}/LaunchDaemons/${PL}.Root.plist
echo
fi
echo It is recommended to disable System Integrity Protection for increased performance.
diff --git a/src/afl-fuzz-init.c b/src/afl-fuzz-init.c
index 5a530821..4c09fab7 100644
--- a/src/afl-fuzz-init.c
+++ b/src/afl-fuzz-init.c
@@ -2270,7 +2270,7 @@ void check_crash_handling(void) {
reporting the awful way. */
#if !TARGET_OS_IPHONE
- if (system("launchctl list 2>/dev/null | grep -q '\\.ReportCrash$'")) return;
+ if (system("launchctl list 2>/dev/null | grep -q '\\.ReportCrash\\>'")) return;
SAYF(
"\n" cLRD "[-] " cRST