projects
/
platform
/
upstream
/
btrfs-progs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
libbtrfsutil: copy in Btrfs UAPI headers
[platform/upstream/btrfs-progs.git]
/
send-stream.c
diff --git
a/send-stream.c
b/send-stream.c
index
920c742
..
78f2571
100644
(file)
--- a/
send-stream.c
+++ b/
send-stream.c
@@
-74,7
+74,7
@@
static int read_buf(struct btrfs_send_stream *sctx, char *buf, size_t len)
ret = 0;
out_eof:
- if (pos < len) {
+ if (
0 < pos &&
pos < len) {
error("short read from stream: expected %zu read %zu", len, pos);
ret = -EIO;
} else {
@@
-492,7
+492,7
@@
int btrfs_read_and_process_send_stream(int fd,
if (ret < 0)
goto out;
if (ret) {
- ret =
1
;
+ ret =
-ENODATA
;
goto out;
}