فهرست منبع

Better error handling

nwin 11 سال پیش
والد
کامیت
4fd832aa5b
1فایلهای تغییر یافته به همراه10 افزوده شده و 4 حذف شده
  1. 10 4
      src/xattr/xattr_darwin.rs

+ 10 - 4
src/xattr/xattr_darwin.rs

@@ -87,12 +87,18 @@ impl Attribute {
                 }
                 Ok(names)
             } else {
-                // Ignore error for now
-                Ok(Vec::new())
+                Err(io::IoError {
+                    kind: io::OtherIoError,
+                    desc: "could not read extended attributes",
+                    detail: None
+                })
             }
         } else {
-            // Ignore error for now
-            Ok(Vec::new())
+            Err(io::IoError {
+                kind: io::OtherIoError,
+                desc: "could not read extended attributes",
+                detail: None
+            })
         }
     }