Skip to content

Commit 3c393c4

Browse files
committed
Fix for payload size scoping in CLI version
1 parent 3b881e7 commit 3c393c4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/github.com/arduino-libraries/WiFi101-FirmwareUpdater/cli/main/winc1500-uploader.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,11 @@ func main() {
8181

8282
// Check maximum supported payload size
8383
log.Println("Reading max payload size")
84-
payloadSize, err := f.GetMaximumPayloadSize()
84+
_payloadSize, err := f.GetMaximumPayloadSize()
8585
if err != nil {
8686
log.Fatal(err)
87+
} else {
88+
payloadSize = _payloadSize
8789
}
8890
if payloadSize < 1024 {
8991
log.Fatalf("Programmer reports %d as maximum payload size (1024 is needed)", payloadSize)

0 commit comments

Comments
 (0)