Hello community,

here is the log from the commit of package syncthing for openSUSE:Factory 
checked in at 2015-11-10 10:03:56
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/syncthing (Old)
 and      /work/SRC/openSUSE:Factory/.syncthing.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "syncthing"

Changes:
--------
--- /work/SRC/openSUSE:Factory/syncthing/syncthing.changes      2015-11-08 
11:26:50.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.syncthing.new/syncthing.changes 2015-11-10 
10:04:16.000000000 +0100
@@ -1,0 +2,7 @@
+Mon Nov  9 06:25:27 UTC 2015 - sor.ale...@meowr.ru
+
+- Update to 1.12.1:
+  * Actually do negative caching on failed discovery lookups.
+- Correct discovery port for SUSEfirewall rule.
+
+-------------------------------------------------------------------

Old:
----
  syncthing-0.12.0.tar.gz

New:
----
  syncthing-0.12.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ syncthing.spec ++++++
--- /var/tmp/diff_new_pack.ohA2B6/_old  2015-11-10 10:04:17.000000000 +0100
+++ /var/tmp/diff_new_pack.ohA2B6/_new  2015-11-10 10:04:17.000000000 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           syncthing
-Version:        0.12.0
+Version:        0.12.1
 Release:        0
 Summary:        FOSS Continuous File Synchronisation
 License:        MPL-2.0

++++++ syncthing-0.12.0.tar.gz -> syncthing-0.12.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/cmd/syncthing/usage_report.go 
new/syncthing-0.12.1/cmd/syncthing/usage_report.go
--- old/syncthing-0.12.0/cmd/syncthing/usage_report.go  2015-11-05 
16:47:06.000000000 +0100
+++ new/syncthing-0.12.1/cmd/syncthing/usage_report.go  2015-11-06 
17:14:20.000000000 +0100
@@ -201,7 +201,7 @@
        defaultRelayServers, otherRelayServers := 0, 0
        for _, addr := range cfg.Options().RelayServers {
                switch addr {
-               case "dynamic+https://relays.syncthing.net":
+               case "dynamic+https://relays.syncthing.net/endpoint":
                        defaultRelayServers++
                default:
                        otherRelayServers++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/lib/config/config.go 
new/syncthing-0.12.1/lib/config/config.go
--- old/syncthing-0.12.0/lib/config/config.go   2015-11-05 16:47:06.000000000 
+0100
+++ new/syncthing-0.12.1/lib/config/config.go   2015-11-06 17:14:20.000000000 
+0100
@@ -175,7 +175,7 @@
        cfg.Options.ListenAddress = uniqueStrings(cfg.Options.ListenAddress)
        cfg.Options.GlobalAnnServers = 
uniqueStrings(cfg.Options.GlobalAnnServers)
 
-       if cfg.Version < OldestHandledVersion {
+       if cfg.Version > 0 && cfg.Version < OldestHandledVersion {
                l.Warnf("Configuration version %d is deprecated. Attempting 
best effort conversion, but please verify manually.", cfg.Version)
        }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/lib/config/config_test.go 
new/syncthing-0.12.1/lib/config/config_test.go
--- old/syncthing-0.12.0/lib/config/config_test.go      2015-11-05 
16:47:06.000000000 +0100
+++ new/syncthing-0.12.1/lib/config/config_test.go      2015-11-06 
17:14:20.000000000 +0100
@@ -104,6 +104,13 @@
                        },
                }
 
+               // The cachedPath will have been resolved to an absolute path,
+               // depending on where the tests are running. Zero it out so we 
don't
+               // fail based on that.
+               for i := range cfg.Folders {
+                       cfg.Folders[i].cachedPath = ""
+               }
+
                if runtime.GOOS != "windows" {
                        expectedFolders[0].RawPath += string(filepath.Separator)
                }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/lib/config/folderconfiguration.go 
new/syncthing-0.12.1/lib/config/folderconfiguration.go
--- old/syncthing-0.12.0/lib/config/folderconfiguration.go      2015-11-05 
16:47:06.000000000 +0100
+++ new/syncthing-0.12.1/lib/config/folderconfiguration.go      2015-11-06 
17:14:20.000000000 +0100
@@ -36,7 +36,8 @@
        PullerPauseS          int                         `xml:"pullerPauseS" 
json:"pullerPauseS"`
        MaxConflicts          int                         `xml:"maxConflicts" 
json:"maxConflicts"`
 
-       Invalid string `xml:"-" json:"invalid"` // Set at runtime when there is 
an error, not saved
+       Invalid    string `xml:"-" json:"invalid"` // Set at runtime when there 
is an error, not saved
+       cachedPath string
 }
 
 type FolderDeviceConfiguration struct {
@@ -55,28 +56,11 @@
        // This is intentionally not a pointer method, because things like
        // cfg.Folders["default"].Path() should be valid.
 
-       // Attempt tilde expansion; leave unchanged in case of error
-       if path, err := osutil.ExpandTilde(f.RawPath); err == nil {
-               f.RawPath = path
-       }
-
-       // Attempt absolutification; leave unchanged in case of error
-       if !filepath.IsAbs(f.RawPath) {
-               // Abs() looks like a fairly expensive syscall on Windows, while
-               // IsAbs() is a whole bunch of string mangling. I think IsAbs() 
may be
-               // somewhat faster in the general case, hence the outer if...
-               if path, err := filepath.Abs(f.RawPath); err == nil {
-                       f.RawPath = path
-               }
+       if f.cachedPath == "" {
+               l.Infoln("bug: uncached path call (should only happen in 
tests)")
+               return f.cleanedPath()
        }
-
-       // Attempt to enable long filename support on Windows. We may still not
-       // have an absolute path here if the previous steps failed.
-       if runtime.GOOS == "windows" && filepath.IsAbs(f.RawPath) && 
!strings.HasPrefix(f.RawPath, `\\`) {
-               return `\\?\` + f.RawPath
-       }
-
-       return f.RawPath
+       return f.cachedPath
 }
 
 func (f *FolderConfiguration) CreateMarker() error {
@@ -129,6 +113,8 @@
                f.RawPath = f.RawPath + string(filepath.Separator)
        }
 
+       f.cachedPath = f.cleanedPath()
+
        if f.ID == "" {
                f.ID = "default"
        }
@@ -140,6 +126,33 @@
        }
 }
 
+func (f *FolderConfiguration) cleanedPath() string {
+       cleaned := f.RawPath
+
+       // Attempt tilde expansion; leave unchanged in case of error
+       if path, err := osutil.ExpandTilde(cleaned); err == nil {
+               cleaned = path
+       }
+
+       // Attempt absolutification; leave unchanged in case of error
+       if !filepath.IsAbs(cleaned) {
+               // Abs() looks like a fairly expensive syscall on Windows, while
+               // IsAbs() is a whole bunch of string mangling. I think IsAbs() 
may be
+               // somewhat faster in the general case, hence the outer if...
+               if path, err := filepath.Abs(cleaned); err == nil {
+                       cleaned = path
+               }
+       }
+
+       // Attempt to enable long filename support on Windows. We may still not
+       // have an absolute path here if the previous steps failed.
+       if runtime.GOOS == "windows" && filepath.IsAbs(cleaned) && 
!strings.HasPrefix(f.RawPath, `\\`) {
+               return `\\?\` + cleaned
+       }
+
+       return cleaned
+}
+
 type FolderDeviceConfigurationList []FolderDeviceConfiguration
 
 func (l FolderDeviceConfigurationList) Less(a, b int) bool {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/lib/db/benchmark_test.go 
new/syncthing-0.12.1/lib/db/benchmark_test.go
--- old/syncthing-0.12.0/lib/db/benchmark_test.go       2015-11-05 
16:47:06.000000000 +0100
+++ new/syncthing-0.12.1/lib/db/benchmark_test.go       2015-11-06 
17:14:20.000000000 +0100
@@ -17,8 +17,6 @@
 
        "github.com/syncthing/syncthing/lib/db"
        "github.com/syncthing/syncthing/lib/protocol"
-       "github.com/syndtr/goleveldb/leveldb"
-       "github.com/syndtr/goleveldb/leveldb/opt"
 )
 
 var files, oneFile, firstHalf, secondHalf []protocol.FileInfo
@@ -44,16 +42,16 @@
        fs.Replace(protocol.LocalDeviceID, firstHalf)
 }
 
-func tempDB() (*leveldb.DB, string) {
+func tempDB() (*db.Instance, string) {
        dir, err := ioutil.TempDir("", "syncthing")
        if err != nil {
                panic(err)
        }
-       db, err := leveldb.OpenFile(filepath.Join(dir, "db"), 
&opt.Options{OpenFilesCacheCapacity: 100})
+       dbi, err := db.Open(filepath.Join(dir, "db"))
        if err != nil {
                panic(err)
        }
-       return db, dir
+       return dbi, dir
 }
 
 func BenchmarkReplaceAll(b *testing.B) {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/syncthing-0.12.0/lib/discover/cache.go 
new/syncthing-0.12.1/lib/discover/cache.go
--- old/syncthing-0.12.0/lib/discover/cache.go  2015-11-05 16:47:06.000000000 
+0100
+++ new/syncthing-0.12.1/lib/discover/cache.go  2015-11-06 17:14:20.000000000 
+0100
@@ -109,6 +109,12 @@
                                when:   time.Now(),
                                found:  len(td)+len(tr) > 0,
                        })
+               } else {
+                       // Lookup returned error, add a negative cache entry.
+                       m.caches[i].Set(deviceID, CacheEntry{
+                               when:  time.Now(),
+                               found: false,
+                       })
                }
        }
        m.mut.Unlock()

++++++ syncthing.firewall ++++++
--- /var/tmp/diff_new_pack.ohA2B6/_old  2015-11-10 10:04:18.000000000 +0100
+++ /var/tmp/diff_new_pack.ohA2B6/_new  2015-11-10 10:04:18.000000000 +0100
@@ -5,4 +5,4 @@
 TCP="22000"
 
 # space separated list of allowed UDP ports
-UDP="21025:21026"
+UDP="21027"


Reply via email to