syncthing/lib/config
Jakob Borg 39899e40bf cmd/syncthing: Use ReadAll + json.Unmarshal in places were we care about consuming the reader
Because json.NewDecoder(r).Decode(&v) doesn't necessarily consume all
data on the reader, that means an HTTP connection can't be reused. We
don't do a lot of HTTP traffic where we read JSON responses, but the
discovery is one such place. The other two are for POSTs from the GUI,
where it's not exactly critical but still nice if the connection still
can be keep-alive'd after the request as well.

Also ensure that we call req.Body.Close() for clarity, even though this
should by all accounts not really be necessary.

GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3050
2016-05-06 22:01:56 +00:00
..
testdata lib/connections: Refactor 2016-05-04 19:38:12 +00:00
commit_test.go mv internal lib 2015-08-09 09:35:26 +02:00
config_test.go lib/connections: Refactor 2016-05-04 19:38:12 +00:00
config.go cmd/syncthing: Use ReadAll + json.Unmarshal in places were we care about consuming the reader 2016-05-06 22:01:56 +00:00
debug.go Implement facility based logger, debugging via REST API 2015-10-03 18:09:53 +02:00
deviceconfiguration.go Use constructor functions for FolderConfiguration and DeviceConfiguration 2015-11-07 09:50:04 +01:00
folderconfiguration.go lib/config: Change folder type attribute to a FolderType type 2016-05-04 11:26:36 +00:00
foldertype.go lib/config: Change folder type attribute to a FolderType type 2016-05-04 11:26:36 +00:00
guiconfiguration.go Rename RawAPIKey -> APIKey in GUIConfiguration 2016-02-02 11:12:25 +01:00
optionsconfiguration.go lib/connections: Refactor 2016-05-04 19:38:12 +00:00
pullorder.go pulorder.go -> pullorder.go 2015-10-27 12:14:14 +01:00
versioningconfiguration.go Fix some config Copy() things we had forgotten 2015-10-27 11:53:42 +01:00
wrapper.go lib/connections: Refactor 2016-05-04 19:38:12 +00:00