# HG changeset patch # User markus schnalke # Date 1319543503 -7200 # Node ID f122535c589eeb3241968d5e3d1df6f9435adda8 # Parent d86d7b4b8995fc0226397633b1851569970778e2 Refactoring: early failure exit. diff -r d86d7b4b8995 -r f122535c589e src/smtp_out.c --- a/src/smtp_out.c Tue Oct 25 13:50:27 2011 +0200 +++ b/src/smtp_out.c Tue Oct 25 13:51:43 2011 +0200 @@ -519,14 +519,13 @@ DEBUG(5) debugf("smtp_out_open_child entered, cmd = %s\n", cmd); psb->remote_host = host; sock = child(cmd); - if (sock > 0) { - psb = create_smtpbase(sock); - psb->remote_host = NULL; + if (sock <= 0) { + return NULL; + } + psb = create_smtpbase(sock); + psb->remote_host = NULL; - return psb; - } - - return NULL; + return psb; } gboolean