coreos / go-tcmu

Go SCSI emulation via the Linux TCM in Userspace module
Apache License 2.0
53 stars 26 forks source link

cmd_handler: check error before checking the result of length #10

Open nak3 opened 7 years ago

nak3 commented 7 years ago

cmd_handler: check error before checking the result of length

This patch swaps the order of error check and write/read result check.

Fixes https://github.com/coreos/go-tcmu/issues/9