summaryrefslogtreecommitdiff
path: root/src/sysctl/sysctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sysctl/sysctl.c')
-rw-r--r--src/sysctl/sysctl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sysctl/sysctl.c b/src/sysctl/sysctl.c
index 8868732ad1..283eefe1a1 100644
--- a/src/sysctl/sysctl.c
+++ b/src/sysctl/sysctl.c
@@ -65,7 +65,7 @@ static int apply_sysctl(const char *property, const char *value) {
log_debug("Setting '%s' to '%s'", property, value);
- p = new(char, sizeof("/proc/sys/") + strlen(property));
+ p = new(char, strlen("/proc/sys/") + strlen(property) + 1);
if (!p)
return log_oom();