aboutsummaryrefslogtreecommitdiff
path: root/libc/bionic/sysprop_helpers.cpp
diff options
context:
space:
mode:
authorMitch Phillips <mitchp@google.com>2022-06-23 11:07:00 -0700
committerMitch Phillips <mitchp@google.com>2022-06-30 18:17:12 +0000
commit23f0befcc2aecabb5fbfd1b2159389eefc9d4018 (patch)
tree309bf4d1501443a20c23936ac0029e0a5bd84fae /libc/bionic/sysprop_helpers.cpp
parent35dbeecf0a15d2566dff2125da587ef458277bb9 (diff)
Add persistent GWP-ASan sysprops.
Adds persistent sysprops for test infra usage, and adds the tests for the sysprops. The test does some fancy flocking in order to restore any existing GWP-ASan sysprop usage in the test cleanup. Bug: 236738714 Test: atest bionic-unit-tests Ignore-AOSP-First: cherry-pick to internal branch Change-Id: I8956296d39c98ce8c7dd0a703b240530d8ad48db Merged-In: I8956296d39c98ce8c7dd0a703b240530d8ad48db
Diffstat (limited to 'libc/bionic/sysprop_helpers.cpp')
-rw-r--r--libc/bionic/sysprop_helpers.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/bionic/sysprop_helpers.cpp b/libc/bionic/sysprop_helpers.cpp
index edae6cc84..10da3efc2 100644
--- a/libc/bionic/sysprop_helpers.cpp
+++ b/libc/bionic/sysprop_helpers.cpp
@@ -53,7 +53,7 @@ static bool get_property_value(const char* property_name, char* dest, size_t des
strncpy(cb_cookie->dest, value, cb_cookie->size);
},
&cb_cookie);
- if (*dest != '\0' && *dest != '0') return true;
+ if (*dest != '\0') return true;
return false;
}