Workaround FUSE missing the generally broken Linux kernel charset support.
[captive.git] / src / client / fuse / op_getattr.c
index f72a8a9..7d1b88e 100644 (file)
@@ -30,6 +30,7 @@
 #include "main.h"
 #include "gnomevfsresult.h"
 #include "capfuse_captive_file_info_object.h"
+#include "utf8.h"
 
 
 int op_getattr(const char *path,struct stat *buf)
@@ -42,6 +43,8 @@ int errint;
        g_return_val_if_fail(path!=NULL,-EINVAL);
        g_return_val_if_fail(buf!=NULL,-EINVAL);
 
+  path=CAPFUSE_FILENAME_TO_UTF8_ALLOCA(path);
+
        if (GNOME_VFS_OK!=(errvfsresult=captive_file_new_open(&captive_file_object,capfuse_captive_vfs_object,path,0)))
                return -gnomevfsresult_to_errno(errvfsresult);