From: Ralph Corderoy Date: Fri, 21 Oct 2016 23:41:44 +0000 (+0100) Subject: Move smtp_init's last-ditch attempt for client inside first test. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/e6e854a44d877408fbe8e55fd71abb1c40150d3c?hp=11e1e41683f5897ebd3dbb0f2f6b58e41e918fb3 Move smtp_init's last-ditch attempt for client inside first test. No point checking it twice in a row if it was false the first time. --- diff --git a/mts/smtp/smtp.c b/mts/smtp/smtp.c index f4308ba5..7b706e01 100644 --- a/mts/smtp/smtp.c +++ b/mts/smtp/smtp.c @@ -128,14 +128,13 @@ smtp_init (char *client, char *server, char *port, int watch, int verbose, } else { client = LocalName(1); /* no clientname -> LocalName */ } - } - - /* - * Last-ditch check just in case client still isn't set to anything - */ - if (client == NULL || *client == '\0') - client = "localhost"; + /* + * Last-ditch check just in case client still isn't set to anything + */ + if (client == NULL || *client == '\0') + client = "localhost"; + } nsc = netsec_init();