diff --git a/release/sysinstall/ftp.c b/release/sysinstall/ftp.c index f83dfdae5a97..0cbb53ffc91b 100644 --- a/release/sysinstall/ftp.c +++ b/release/sysinstall/ftp.c @@ -98,7 +98,7 @@ try: sprintf(password, "installer@%s", variable_get(VAR_HOSTNAME)); msgNotify("Logging in to %s@%s..", login_name, hostname); if ((OpenConn = ftpLogin(hostname, login_name, password, FtpPort, isDebug(), &code)) == NULL) { - msgConfirm("Couldn't open FTP connection to %s, errcode = %d", hostname, code); + msgConfirm("Couldn't open FTP connection to %s:\n %s.", hostname, ftpErrString(code)); goto punt; } @@ -110,7 +110,7 @@ try: msgConfirm("No such directory ftp://%s/%s\n" "please check your URL and try again.", hostname, dir); else - msgConfirm("FTP chdir to ftp://%s/%s returned error status %d\n", hostname, dir, i); + msgConfirm("FTP chdir to ftp://%s/%s returned error status:\n %s.", hostname, dir, ftpErrString(i)); goto punt; } } diff --git a/release/sysinstall/index.c b/release/sysinstall/index.c index 79a035814d3e..736e2575e585 100644 --- a/release/sysinstall/index.c +++ b/release/sysinstall/index.c @@ -430,7 +430,7 @@ pkg_fire(dialogMenuItem *self) msgInfo("Added %s to selection list", kp->name); } } - else if (sp) { + else { msgInfo("Removed %s from selection list", kp->name); index_delete(sp); } diff --git a/release/sysinstall/main.c b/release/sysinstall/main.c index 688000062255..d9b08a899b7d 100644 --- a/release/sysinstall/main.c +++ b/release/sysinstall/main.c @@ -81,10 +81,10 @@ main(int argc, char **argv) if (OnVTY) { for (curr = 0; curr < 25; curr++) putchar('\n'); - /* Move stderr aside */ - if (DebugFD) - dup2(DebugFD, 2); } + /* Move stderr aside */ + if (DebugFD) + dup2(DebugFD, 2); /* Probe for all relevant devices on the system */ deviceGetAll(); diff --git a/release/sysinstall/package.c b/release/sysinstall/package.c index 0ae2d50ac2a6..78074d772a97 100644 --- a/release/sysinstall/package.c +++ b/release/sysinstall/package.c @@ -63,8 +63,8 @@ package_exists(char *name) */ snprintf(fname, FILENAME_MAX, "/var/db/pkg/%s", name); status = access(fname, R_OK); - msgDebug("package check for %s returns %s.\n", name, - status ? "failure" : "success"); + if (isDebug()) + msgDebug("package check for %s returns %s.\n", name, status ? "failure" : "success"); return !status; } diff --git a/usr.sbin/sade/main.c b/usr.sbin/sade/main.c index 688000062255..d9b08a899b7d 100644 --- a/usr.sbin/sade/main.c +++ b/usr.sbin/sade/main.c @@ -81,10 +81,10 @@ main(int argc, char **argv) if (OnVTY) { for (curr = 0; curr < 25; curr++) putchar('\n'); - /* Move stderr aside */ - if (DebugFD) - dup2(DebugFD, 2); } + /* Move stderr aside */ + if (DebugFD) + dup2(DebugFD, 2); /* Probe for all relevant devices on the system */ deviceGetAll(); diff --git a/usr.sbin/sysinstall/ftp.c b/usr.sbin/sysinstall/ftp.c index f83dfdae5a97..0cbb53ffc91b 100644 --- a/usr.sbin/sysinstall/ftp.c +++ b/usr.sbin/sysinstall/ftp.c @@ -98,7 +98,7 @@ try: sprintf(password, "installer@%s", variable_get(VAR_HOSTNAME)); msgNotify("Logging in to %s@%s..", login_name, hostname); if ((OpenConn = ftpLogin(hostname, login_name, password, FtpPort, isDebug(), &code)) == NULL) { - msgConfirm("Couldn't open FTP connection to %s, errcode = %d", hostname, code); + msgConfirm("Couldn't open FTP connection to %s:\n %s.", hostname, ftpErrString(code)); goto punt; } @@ -110,7 +110,7 @@ try: msgConfirm("No such directory ftp://%s/%s\n" "please check your URL and try again.", hostname, dir); else - msgConfirm("FTP chdir to ftp://%s/%s returned error status %d\n", hostname, dir, i); + msgConfirm("FTP chdir to ftp://%s/%s returned error status:\n %s.", hostname, dir, ftpErrString(i)); goto punt; } } diff --git a/usr.sbin/sysinstall/index.c b/usr.sbin/sysinstall/index.c index 79a035814d3e..736e2575e585 100644 --- a/usr.sbin/sysinstall/index.c +++ b/usr.sbin/sysinstall/index.c @@ -430,7 +430,7 @@ pkg_fire(dialogMenuItem *self) msgInfo("Added %s to selection list", kp->name); } } - else if (sp) { + else { msgInfo("Removed %s from selection list", kp->name); index_delete(sp); } diff --git a/usr.sbin/sysinstall/main.c b/usr.sbin/sysinstall/main.c index 688000062255..d9b08a899b7d 100644 --- a/usr.sbin/sysinstall/main.c +++ b/usr.sbin/sysinstall/main.c @@ -81,10 +81,10 @@ main(int argc, char **argv) if (OnVTY) { for (curr = 0; curr < 25; curr++) putchar('\n'); - /* Move stderr aside */ - if (DebugFD) - dup2(DebugFD, 2); } + /* Move stderr aside */ + if (DebugFD) + dup2(DebugFD, 2); /* Probe for all relevant devices on the system */ deviceGetAll(); diff --git a/usr.sbin/sysinstall/package.c b/usr.sbin/sysinstall/package.c index 0ae2d50ac2a6..78074d772a97 100644 --- a/usr.sbin/sysinstall/package.c +++ b/usr.sbin/sysinstall/package.c @@ -63,8 +63,8 @@ package_exists(char *name) */ snprintf(fname, FILENAME_MAX, "/var/db/pkg/%s", name); status = access(fname, R_OK); - msgDebug("package check for %s returns %s.\n", name, - status ? "failure" : "success"); + if (isDebug()) + msgDebug("package check for %s returns %s.\n", name, status ? "failure" : "success"); return !status; }