From 92625d852a1e2a4e188bc285c2341f4c482c0469 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sun, 18 Dec 2016 04:00:04 -0500 Subject: gofmt --- sd_daemon/Makefile | 2 +- sd_daemon/listen_fds.go | 2 +- sd_daemon/log.go | 6 +++--- sd_daemon/notify.go | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sd_daemon/Makefile b/sd_daemon/Makefile index ec66e67..1d8579e 100644 --- a/sd_daemon/Makefile +++ b/sd_daemon/Makefile @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -files.src.gen = log_util.go +files.src.gen += log_util.go files.generate: $(files.src.gen) maintainer-clean: diff --git a/sd_daemon/listen_fds.go b/sd_daemon/listen_fds.go index f512384..bf30432 100644 --- a/sd_daemon/listen_fds.go +++ b/sd_daemon/listen_fds.go @@ -54,7 +54,7 @@ func ListenFds(unsetEnv bool) []*os.File { files := make([]*os.File, 0, nfds) for i := 0; i < nfds; i++ { - fd := i+3 + fd := i + 3 syscall.CloseOnExec(fd) name := "unknown" if i < len(names) { diff --git a/sd_daemon/log.go b/sd_daemon/log.go index 76a735f..df82d4b 100644 --- a/sd_daemon/log.go +++ b/sd_daemon/log.go @@ -17,12 +17,12 @@ package sd_daemon import ( + "fmt" "io" + "log/syslog" "os" "strings" "sync" - "fmt" - "log/syslog" ) // Logger writes ""-prefixed lines to an io.Writer, where N is a @@ -33,7 +33,7 @@ import ( // constant "Log", which uses os.Stderr as the writer. It is // implemented as a struct rather than a set of functions so that it // can be passed around as an implementation of an interface. -type Logger struct{ +type Logger struct { mu sync.Mutex out io.Writer } diff --git a/sd_daemon/notify.go b/sd_daemon/notify.go index ad63659..360e364 100644 --- a/sd_daemon/notify.go +++ b/sd_daemon/notify.go @@ -17,10 +17,10 @@ package sd_daemon import ( + "bytes" "net" "os" "syscall" - "bytes" ) // Notify sends a message from process pid to the service manager -- cgit v1.2.3