Index: trunk/src_plugins/lib_vfs/lib_vfs.c =================================================================== --- trunk/src_plugins/lib_vfs/lib_vfs.c (revision 24148) +++ trunk/src_plugins/lib_vfs/lib_vfs.c (revision 24149) @@ -115,20 +115,18 @@ pcb_propval_t *pv; htprop_entry_t *e; - if (*path == '\0') { - if (isdir != NULL) - *isdir = 1; - if (wr == 0) - return 0; - return -1; - } + if ((*path == '\0') || (strcmp(path, "p") == 0)) + goto ret_dir; pcb_propsel_map_core(pctx); pt = htsp_get(&pctx->props, path); if (pt == NULL) - return -1; + goto ret_dir; /* trust our listing */ + if (isdir != NULL) + *isdir = 0; + if (wr) { pcb_propset_ctx_t sctx; sctx.s = data->array; @@ -136,7 +134,6 @@ return pcb_propsel_set(pctx, path, &sctx) == 1; } - e = htprop_first(&pt->values); pv = &e->key; @@ -148,6 +145,13 @@ } return 0; + + ret_dir:; + if (isdir != NULL) + *isdir = 1; + if (wr == 0) + return 0; + return -1; } static void vfs_list_obj(pcb_board_t *pcb, gds_t *path, pcb_any_obj_t *obj, pcb_vfs_list_cb cb, void *ctx)