X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?p=ngircd-alex.git;a=blobdiff_plain;f=src%2Fngircd%2Fngircd.c;h=c2169c4377af04b1f2c11884903ed5b26341a56a;hp=e9faa65734c83369232926940881373cc89cb780;hb=HEAD;hpb=0061394d7fe684ea444cf021d48c9674a45c82df diff --git a/src/ngircd/ngircd.c b/src/ngircd/ngircd.c index e9faa657..c2169c43 100644 --- a/src/ngircd/ngircd.c +++ b/src/ngircd/ngircd.c @@ -92,8 +92,6 @@ main(int argc, const char *argv[]) #ifdef SNIFFER NGIRCd_Sniffer = false; #endif - strlcpy(NGIRCd_ConfFile, SYSCONFDIR, sizeof(NGIRCd_ConfFile)); - strlcat(NGIRCd_ConfFile, CONFIG_FILE, sizeof(NGIRCd_ConfFile)); Fill_Version(); @@ -724,7 +722,7 @@ NGIRCd_Init(bool NGIRCd_NoDaemon) Log(LOG_ERR, "Can't change group ID to %s(%u): %s!", grp ? grp->gr_name : "?", Conf_GID, strerror(real_errno)); - if (real_errno != EPERM) + if (real_errno != EPERM && real_errno != EINVAL) goto out; } #ifdef HAVE_SETGROUPS @@ -750,7 +748,7 @@ NGIRCd_Init(bool NGIRCd_NoDaemon) Log(LOG_ERR, "Can't change user ID to %s(%u): %s!", pwd ? pwd->pw_name : "?", Conf_UID, strerror(real_errno)); - if (real_errno != EPERM) + if (real_errno != EPERM && real_errno != EINVAL) goto out; } } @@ -758,7 +756,7 @@ NGIRCd_Init(bool NGIRCd_NoDaemon) initialized = true; /* Normally a child process is forked which isn't any longer - * connected to ther controlling terminal. Use "--nodaemon" + * connected to the controlling terminal. Use "--nodaemon" * to disable this "daemon mode" (useful for debugging). */ if (!NGIRCd_NoDaemon) { pid = fork(); @@ -828,7 +826,7 @@ NGIRCd_Init(bool NGIRCd_NoDaemon) "Can't change working directory to \"%s\": %s!", pwd->pw_dir, strerror(errno)); } else - Log(LOG_ERR, "Can't get user informaton for UID %d!?", Conf_UID); + Log(LOG_ERR, "Can't get user information for UID %d!?", Conf_UID); return true; out: