From: Simon Wilkinson Date: Fri, 22 Feb 2013 10:23:43 +0000 (+0000) Subject: viced: Allow GetCapabilities to return an error X-Git-Tag: upstream/1.8.0_pre1^2~1440 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=ea0441520138d2129b5c6b2bd16c7640a8680146;p=packages%2Fo%2Fopenafs.git viced: Allow GetCapabilities to return an error At the moment, the GetCapabilities RPC handler ignors errors from CallPreamble or CallPostamble. Instead of silently swallowing these, and potentially reutnring a bogus capabilities structure, make it possible for the RPC to return failure to the caller. Caught by clang-analyzer Change-Id: Ic36e59e8cce8be4920f041a86d5636d54668d887 Reviewed-on: http://gerrit.openafs.org/9241 Tested-by: BuildBot Reviewed-by: Derrick Brashear Reviewed-by: Jeffrey Altman --- diff --git a/src/viced/afsfileprocs.c b/src/viced/afsfileprocs.c index b27d7ddbf..0998fae61 100644 --- a/src/viced/afsfileprocs.c +++ b/src/viced/afsfileprocs.c @@ -5648,7 +5648,7 @@ SRXAFS_GetCapabilities(struct rx_call * acall, Capabilities * capabilities) code = CallPostamble(tcon, code, thost); - return 0; + return code; } /* client is held, but not locked */