aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org>2020-10-08 13:34:07 +0300
committerSergey Poznyakoff <gray@gnu.org>2020-10-08 13:34:07 +0300
commitfc632d0ec798f3d4756aa29c0002a69ef3b108e7 (patch)
tree74ef0b44e5f017d83b853cd5e1b3dc01f1095e15
parent4e32438d193f116882d177d61e2a1e8ca946b5fe (diff)
downloadhostproc-fc632d0ec798f3d4756aa29c0002a69ef3b108e7.tar.gz
hostproc-fc632d0ec798f3d4756aa29c0002a69ef3b108e7.tar.bz2
Fix typo.
-rw-r--r--main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main.c b/main.c
index 09b8cde..1ad3a26 100644
--- a/main.c
+++ b/main.c
@@ -399,7 +399,7 @@ main(int argc, char **argv)
netsnmp_ds_set_boolean(NETSNMP_DS_APPLICATION_ID,
NETSNMP_DS_AGENT_ROLE, 1);
- if (getpid() && !getenv("SNMP_PERSISTENT_DIR")) {
+ if (getuid() && !getenv("SNMP_PERSISTENT_DIR")) {
/* Set a reasonable persistent directory */
char *user_snmp_dir = make_file_name(getenv("HOME"), ".snmp");
char *persist_dir = make_file_name(user_snmp_dir, "persist");

Return to:

Send suggestions and report system problems to the System administrator.