diff options
Diffstat (limited to 'camlibs/barbie/barbie.c')
-rw-r--r-- | camlibs/barbie/barbie.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/camlibs/barbie/barbie.c b/camlibs/barbie/barbie.c index a13bef376..9c7d0d3cc 100644 --- a/camlibs/barbie/barbie.c +++ b/camlibs/barbie/barbie.c @@ -102,7 +102,7 @@ int camera_init(Camera *camera) { gp_port_open(b->dev); /* Create the filesystem */ - b->fs = gp_filesystem_new(); + gp_filesystem_new(&b->fs); return (barbie_ping(b)); } @@ -130,14 +130,17 @@ int camera_folder_list_files (Camera *camera, const char *folder, CameraList *li int count, x; BarbieStruct *b = (BarbieStruct*)camera->camlib_data; + const char *name; count = barbie_file_count(b); /* Populate the filesystem */ gp_filesystem_populate (b->fs, "/", "mattel%02i.ppm", count); - for (x = 0; x < gp_filesystem_count (b->fs, folder); x++) - gp_list_append (list, gp_filesystem_name (b->fs, folder, x)); + for (x = 0; x < gp_filesystem_count (b->fs, folder); x++) { + gp_filesystem_name (b->fs, folder, x, &name); + gp_list_append (list, name, NULL); + } return GP_OK; } |