From: Shenghou Ma Date: Mon, 28 Apr 2014 18:29:45 +0000 (-0400) Subject: log/syslog: document if network=="" for Dial, it will connect to local syslog server. X-Git-Tag: go1.3beta2~170 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=4cc708ae1dc5fd6b8a04ee884e34303b81ddd223;p=gostls13.git log/syslog: document if network=="" for Dial, it will connect to local syslog server. Fixes #7828. LGTM=robert.hencke, iant, bradfitz R=golang-codereviews, robert.hencke, iant, bradfitz CC=golang-codereviews https://golang.org/cl/97780045 --- diff --git a/src/pkg/log/syslog/syslog.go b/src/pkg/log/syslog/syslog.go index 1c7588e365..5e09599162 100644 --- a/src/pkg/log/syslog/syslog.go +++ b/src/pkg/log/syslog/syslog.go @@ -115,9 +115,10 @@ func New(priority Priority, tag string) (w *Writer, err error) { } // Dial establishes a connection to a log daemon by connecting to -// address raddr on the network net. Each write to the returned +// address raddr on the specified network. Each write to the returned // writer sends a log message with the given facility, severity and // tag. +// If network is empty, Dial will connect to the local syslog server. func Dial(network, raddr string, priority Priority, tag string) (*Writer, error) { if priority < 0 || priority > LOG_LOCAL7|LOG_DEBUG { return nil, errors.New("log/syslog: invalid priority")