From e586fda5f2956d7db0913292ec83b19f170fdf26 Mon Sep 17 00:00:00 2001 From: Jakob Borg Date: Thu, 4 Sep 2014 22:03:25 +0200 Subject: [PATCH] Woops, close the right fd --- cmd/syncthing/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/syncthing/main.go b/cmd/syncthing/main.go index a9f24c08..763e99ff 100644 --- a/cmd/syncthing/main.go +++ b/cmd/syncthing/main.go @@ -725,7 +725,7 @@ func archiveLegacyConfig() { l.Warnf("Cannot archive config:", err) return } - defer src.Close() + defer dst.Close() l.Infoln("Archiving config.xml") io.Copy(dst, src)