From f20f67e18c5b3e55012e9a9d6d6a584cc1859b5f Mon Sep 17 00:00:00 2001 From: John Spray Date: Tue, 29 Sep 2015 16:59:41 +0100 Subject: [PATCH] pybind/cephfs: fix DirEntry helpers These were referring to constants incorrectly, would throw exception if called. Signed-off-by: John Spray --- src/pybind/cephfs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pybind/cephfs.py b/src/pybind/cephfs.py index 7aad54e244450..df33da71baaf2 100644 --- a/src/pybind/cephfs.py +++ b/src/pybind/cephfs.py @@ -156,13 +156,13 @@ class DirEntry(namedtuple('DirEntry', DT_REG = 0xA DT_LNK = 0xC def is_dir(self): - return self.d_type == DT_DIR + return self.d_type == self.DT_DIR def is_symbol_file(self): - return self.d_type == DT_LNK + return self.d_type == self.DT_LNK def is_file(self): - return self.d_type == DT_REG + return self.d_type == self.DT_REG StatResult = namedtuple('StatResult', ["st_dev", "st_ino", "st_mode", "st_nlink", "st_uid", -- 2.39.5