]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
osd: cmpext operator should ignore -ENOENT on read 16622/head
authorJason Dillaman <dillaman@redhat.com>
Thu, 27 Jul 2017 11:48:59 +0000 (07:48 -0400)
committerJason Dillaman <dillaman@redhat.com>
Fri, 28 Jul 2017 23:07:13 +0000 (19:07 -0400)
commitea33368c1e6657fd02195e2994385230f520a37c
tree20966e80097a7e8c2ba73cad9cf2bb64682f2bf2
parent06243931adc4192b77ac166834232072b429d7cd
osd: cmpext operator should ignore -ENOENT on read

The operator already handles the case where the object is truncated. If
an RBD user performs a read + cmpext/write of a sparse image, the read
of the missing object would return a zeroed buffer. Using that zeroed
buffer for the cmpext test would fail since it wasn't ignoring the
-ENOENT read failure.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/osd/PrimaryLogPG.cc
src/test/librados/io.cc