upgrade obexd to 0.47
[profile/ivi/obexd.git] / plugins / filesystem.c
index 68785c6..e664fc5 100644 (file)
@@ -488,7 +488,7 @@ static GString *append_listing(GString *object, const char *name,
                goto failed;
        }
 
-       if (root)
+       if (!root)
                object = g_string_append(object, FL_PARENT_FOLDER_ELEMENT);
 
        ret = verify_path(name);
@@ -604,7 +604,7 @@ ssize_t string_read(void *object, void *buf, size_t count)
 
        len = MIN(string->len, count);
        memcpy(buf, string->str, len);
-       string = g_string_erase(string, 0, len);
+       g_string_erase(string, 0, len);
 
        return len;
 }