This repository was archived by the owner on Aug 30, 2024. It is now read-only.
- Notifications
You must be signed in to change notification settings - Fork18
Verify rsync protocol version match prior to proceeding - Rebased on current master.#71
Merged
Uh oh!
There was an error while loading.Please reload this page.
Merged
Changes from1 commit
Commits
Show all changes
7 commits Select commitHold shift + click to select a range
f745670
Verify rsync protocol version match prior to proceeding.
stephenwithav5538af6
Add context to sync.Version.
stephenwithav54cecb2
Correct syncCmd.version, sync.Version.
stephenwithav35ee1de
Update local, remote version checks to avoid blanks.
stephenwithav21976c6
Remove go from io.Copy in internal/sync/sync.go#Version
stephenwithavd853066
Return error directly in internal/sync/sync.go#Version
stephenwithave8abef2
Update [vV]ersion comment strings; remove extraneous error check.
stephenwithavFile filter
Filter by extension
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
Remove go from io.Copy in internal/sync/sync.go#Version
- Loading branch information
Uh oh!
There was an error while loading.Please reload this page.
commit21976c65f28b437d9df10a00ca4851444666ce32
There are no files selected for viewing
4 changes: 2 additions & 2 deletionsinternal/sync/sync.go
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -284,11 +284,11 @@ func (s Sync) Version() (string, error) { | ||||||
return "", err | ||||||
} | ||||||
buf := &bytes.Buffer{} | ||||||
io.Copy(buf, process.Stdout()) | ||||||
err = process.Wait() | ||||||
if code, ok := err.(wsep.ExitError); ok { | ||||||
return "", fmt.Errorf("Versioncheck exit status: %v", code) | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Suggested change
| ||||||
} | ||||||
if err != nil { | ||||||
return "", fmt.Errorf("Server version mismatch") | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. I'd prefer returning the error here instead. | ||||||
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.