Commit 83e4b735 authored by Simon Kelley's avatar Simon Kelley

Remove confusion between --user and --script-user.

parent 6340ca73
...@@ -388,10 +388,12 @@ int main (int argc, char **argv) ...@@ -388,10 +388,12 @@ int main (int argc, char **argv)
daemon->scriptuser && daemon->scriptuser &&
(daemon->lease_change_command || daemon->luascript)) (daemon->lease_change_command || daemon->luascript))
{ {
if ((ent_pw = getpwnam(daemon->scriptuser))) struct passwd *scr_pw;
if ((scr_pw = getpwnam(daemon->scriptuser)))
{ {
script_uid = ent_pw->pw_uid; script_uid = scr_pw->pw_uid;
script_gid = ent_pw->pw_gid; script_gid = scr_pw->pw_gid;
} }
else else
baduser = daemon->scriptuser; baduser = daemon->scriptuser;
...@@ -541,7 +543,7 @@ int main (int argc, char **argv) ...@@ -541,7 +543,7 @@ int main (int argc, char **argv)
{ {
if (!read_write(fd, (unsigned char *)daemon->namebuff, strlen(daemon->namebuff), 0)) if (!read_write(fd, (unsigned char *)daemon->namebuff, strlen(daemon->namebuff), 0))
err = 1; err = 1;
else else
{ {
while (retry_send(close(fd))); while (retry_send(close(fd)));
if (errno != 0) if (errno != 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment