5.005_03-MAINT_TRIAL_5 utils/h2xs fixing -A & more
[p5sagit/p5-mst-13.2.git] / lib / Sys / Syslog.pm
index 1f92e60..f0cbb71 100644 (file)
@@ -48,7 +48,7 @@ Syslog provides the functions:
 =item openlog $ident, $logopt, $facility
 
 I<$ident> is prepended to every message.
-I<$logopt> contains one or more of the words I<pid>, I<ndelay>, I<cons>, I<nowait>.
+I<$logopt> contains zero or more of the words I<pid>, I<ndelay>, I<cons>, I<nowait>.
 I<$facility> specifies the part of the system
 
 =item syslog $priority, $format, @args
@@ -124,7 +124,8 @@ sub openlog {
     $lo_ndelay = $logopt =~ /\bndelay\b/;
     $lo_cons = $logopt =~ /\bcons\b/;
     $lo_nowait = $logopt =~ /\bnowait\b/;
-    &connect if $lo_ndelay;
+    return 1 unless $lo_ndelay;
+    &connect;
 } 
 
 sub closelog {