]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rados.py: make exception with errno string instead of int
authorDan Mick <dan.mick@inktank.com>
Thu, 6 Jun 2013 20:56:54 +0000 (13:56 -0700)
committerDan Mick <dan.mick@inktank.com>
Fri, 7 Jun 2013 01:46:53 +0000 (18:46 -0700)
Signed-off-by: Dan Mick <dan.mick@inktank.com>
src/pybind/rados.py

index 34ac4ae8ade19b873b2352398b6eba2149c89c68..d9980c26504202217c3053be54fe006c93f61e60 100644 (file)
@@ -86,7 +86,7 @@ def make_ex(ret, msg):
     if ret in errors:
         return errors[ret](msg)
     else:
-        return Error(msg + (": error code %d" % ret))
+        return Error(msg + (": errno %s" % errno.errorcode[ret]))
 
 class rados_pool_stat_t(Structure):
     """ Usage information for a pool """