From: Ilya Dryomov Date: Thu, 13 Mar 2014 14:36:14 +0000 (+0200) Subject: libceph: fixup error handling in osdmap_decode() X-Git-Tag: v3.15-rc1~61^2~34 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=597b52f6ca247086371abd67e5083292a500e736;p=pandora-kernel.git libceph: fixup error handling in osdmap_decode() The existing error handling scheme requires resetting err to -EINVAL prior to calling any ceph_decode_* macro. This is ugly and fragile, and there already are a few places where we would return 0 on error, due to a missing reset. Fix this by adding a special e_inval label to be used by all ceph_decode_* macros. Signed-off-by: Ilya Dryomov Reviewed-by: Alex Elder --- Reading git-diff-tree failed