summaryrefslogtreecommitdiff
path: root/libc/system_properties/system_properties.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libc/system_properties/system_properties.cpp')
-rw-r--r--libc/system_properties/system_properties.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/system_properties/system_properties.cpp b/libc/system_properties/system_properties.cpp
index 7c48b8e49..d5c36471d 100644
--- a/libc/system_properties/system_properties.cpp
+++ b/libc/system_properties/system_properties.cpp
@@ -67,7 +67,7 @@ bool SystemProperties::Init(const char* filename) {
return true;
}
- if (strlen(filename) > PROP_FILENAME_MAX) {
+ if (strlen(filename) >= PROP_FILENAME_MAX) {
return false;
}
strcpy(property_filename_, filename);
@@ -95,7 +95,7 @@ bool SystemProperties::Init(const char* filename) {
}
bool SystemProperties::AreaInit(const char* filename, bool* fsetxattr_failed) {
- if (strlen(filename) > PROP_FILENAME_MAX) {
+ if (strlen(filename) >= PROP_FILENAME_MAX) {
return false;
}
strcpy(property_filename_, filename);