Your message dated Sat, 24 Jul 2021 01:04:07 +0000
with message-id <[email protected]>
and subject line Bug#990330: fixed in syncthing 1.12.1~ds1-4
has caused the Debian Bug report #990330,
regarding syncthing: Inconsistent state after accepting new folder
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
990330: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=990330
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: syncthing
Version: 1.12.1~ds1-2
Severity: important

Accepting a new folder can lead to missing files on initial sync. See
upstream bug [1] and PR for details. This can lead to an inconsistent
state, with files not being synced, thus I used severity important.

The patch fixing this is attached.

[1]: https://github.com/syncthing/syncthing/issues/7649




diff --git a/lib/model/indexsender.go b/lib/model/indexsender.go
index 7bca774..8b9e02a 100644
--- a/lib/model/indexsender.go
+++ b/lib/model/indexsender.go
@@ -329,15 +329,15 @@ func (r *indexSenderRegistry) addLocked(folder config.FolderConfiguration, fset
 // addPending stores the given info to start an index sender once resume is called
 // for this folder.
 // If an index sender is already running, it will be stopped.
-func (r *indexSenderRegistry) addPending(folder config.FolderConfiguration, startInfo *indexSenderStartInfo) {
+func (r *indexSenderRegistry) addPending(folderID string, startInfo *indexSenderStartInfo) {
 	r.mut.Lock()
 	defer r.mut.Unlock()
 
-	if is, ok := r.indexSenders[folder.ID]; ok {
+	if is, ok := r.indexSenders[folderID]; ok {
 		r.sup.RemoveAndWait(is.token, 0)
-		delete(r.indexSenders, folder.ID)
+		delete(r.indexSenders, folderID)
 	}
-	r.startInfos[folder.ID] = startInfo
+	r.startInfos[folderID] = startInfo
 }
 
 // remove stops a running index sender or removes one pending to be started.
diff --git a/lib/model/model.go b/lib/model/model.go
index 64e7bc6..1558321 100644
--- a/lib/model/model.go
+++ b/lib/model/model.go
@@ -1252,7 +1252,7 @@ func (m *model) ccHandleFolders(folders []protocol.Folder, deviceCfg config.Devi
 				continue
 			}
 			m.cfg.AddOrUpdatePendingFolder(folder.ID, folder.Label, deviceID)
-			indexSenders.addPending(cfg, ccDeviceInfos[folder.ID])
+			indexSenders.addPending(folder.ID, ccDeviceInfos[folder.ID])
 			changed = true
 			m.evLogger.Log(events.FolderRejected, map[string]string{
 				"folder":      folder.ID,
@@ -1270,7 +1270,7 @@ func (m *model) ccHandleFolders(folders []protocol.Folder, deviceCfg config.Devi
 		}
 
 		if cfg.Paused {
-			indexSenders.addPending(cfg, ccDeviceInfos[folder.ID])
+			indexSenders.addPending(cfg.ID, ccDeviceInfos[folder.ID])
 			continue
 		}
 
@@ -1312,7 +1312,7 @@ func (m *model) ccHandleFolders(folders []protocol.Folder, deviceCfg config.Devi
 			// Shouldn't happen because !cfg.Paused, but might happen
 			// if the folder is about to be unpaused, but not yet.
 			l.Debugln("ccH: no fset", folder.ID)
-			indexSenders.addPending(cfg, ccDeviceInfos[folder.ID])
+			indexSenders.addPending(cfg.ID, ccDeviceInfos[folder.ID])
 			continue
 		}
 

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


--- End Message ---
--- Begin Message ---
Source: syncthing
Source-Version: 1.12.1~ds1-4
Done: Alexandre Viau <[email protected]>

We believe that the bug you reported is fixed in the latest version of
syncthing, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Alexandre Viau <[email protected]> (supplier of updated syncthing package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Fri, 23 Jul 2021 16:27:51 -0400
Source: syncthing
Architecture: source
Version: 1.12.1~ds1-4
Distribution: unstable
Urgency: medium
Maintainer: Debian Go Packaging Team 
<[email protected]>
Changed-By: Alexandre Viau <[email protected]>
Closes: 985938 990330
Changes:
 syncthing (1.12.1~ds1-4) unstable; urgency=medium
 .
   [ Alexandre Viau ]
   * Import patches.
 .
   [ Simone Rossetto ]
   * Fix cannot set more than one option in STDISCOSRV_OPTS
     (Closes: #985938).
 .
   [ Simon Frei ]
   * Fix inconsistent state after accepting new folder (Closes: #990330).
Checksums-Sha1:
 2f1bccabd0aa5185adde0b666d4fc59b9a61393b 3682 syncthing_1.12.1~ds1-4.dsc
 d5cf78facffc7a403183dc3e9010548174b0c8bd 32916 
syncthing_1.12.1~ds1-4.debian.tar.xz
 7d32c22916175082ba6ca0b8a9eed1d7db190b53 10932 
syncthing_1.12.1~ds1-4_source.buildinfo
Checksums-Sha256:
 24defee70f8835f69e526665f1b2d144cd9be1ace52d3f18fda161468b91b37e 3682 
syncthing_1.12.1~ds1-4.dsc
 7874f3d31990cf57b360e1829623ce849636796161eb2159b80f7d4b0eb147c6 32916 
syncthing_1.12.1~ds1-4.debian.tar.xz
 eeb07fe244276f5b160b5e2503d705bab27f99cc762784d7251f0e4880ce3ef2 10932 
syncthing_1.12.1~ds1-4_source.buildinfo
Files:
 6b93076702c57edf68d6472c22739069 3682 utils optional syncthing_1.12.1~ds1-4.dsc
 00412ccafbcf15ee166fee624d67bbed 32916 utils optional 
syncthing_1.12.1~ds1-4.debian.tar.xz
 6af06bd4f0e34c9e0f5538dbd52b673e 10932 utils optional 
syncthing_1.12.1~ds1-4_source.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEB0B3ii38SjnAyLyMjysRPGU1xacFAmD7KDwACgkQjysRPGU1
xadgEg//fT7dwRKWLBJYTsION0Vsl59o1SZFBkHrPl9lQ5Qv+iV2P9zpUn1aG0zq
jY5TSRpuu6AYnntbn0DJ09ngQIEkBtF5BaGi/W5w3PY7UePrV6hm7sJ4QrR+LfOA
eijwk+knxUA+FxQ78iYN4BZt8cTVsrZwH1qLGlIfsQIPUrg/QZj7ulV+ztB5Hc2L
OpDmVA5KHi1FqAGoOHf5VPxMXAV4zcvmiwpy/N+rrJIOLsYW+Fdn9RfL6d7tY08t
hyHXdl76ahSRaNK16pDnX5VzUdrkxrzieP022tt8+yV09P2aqHl+7+Tr6YSuUGHq
vA1wAEBzBShyYGNpbzUPC/EzltocM8jtY1umaZ0nGmDblicxmsutf/aoxFKfqKcz
iI990BrPOet11tVi6geMxDpJcRwHSsFEaQSaCmhRm+EX5iZQc7MVGcQoB9cDmIP2
ThbKTFWsj+slnZ8ell4VF9pmJhGj0EuAdq8FWZvyMr6x71Hy2kYj9tDR3g1YcqEO
NXHmuGM+/itKAT+HqATmueq0GoZ2Q48QvS6NW3wlvw+6057NggnCFC6bd7qFB0xS
prLqolcu2FxzZvhCt6jZ5m2lzfHwISpqTjVK9TkpszrEqUrTAFhZ981t2qUqr3/s
Y3xN0PXxWxmu4vyCiClROSpy3XMunsd6dwSlcUPyJh9ji+EwHRc=
=uC8Z
-----END PGP SIGNATURE-----

--- End Message ---
_______________________________________________
Pkg-go-maintainers mailing list
[email protected]
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-go-maintainers

Reply via email to