Lines Matching refs:device
25 static void prune_empty_folders(LIBMTP_mtpdevice_t *device, LIBMTP_file_t *files, LIBMTP_folder_t *folderlist, int do_delete)
46 if (LIBMTP_Delete_Object(device,folderlist->folder_id) != 0) {
48 LIBMTP_Dump_Errorstack(device);
49 LIBMTP_Clear_Errorstack(device);
55 prune_empty_folders(device,files,folderlist->child,do_delete); // recurse down
56 prune_empty_folders(device,files,folderlist->sibling,do_delete); // recurse along
82 LIBMTP_mtpdevice_t *device;
87 device = LIBMTP_Get_First_Device();
88 if (device == NULL) {
94 files = LIBMTP_Get_Filelisting_With_Callback(device,NULL,NULL);
97 folders = LIBMTP_Get_Folder_List(device);
102 prune_empty_folders(device,files,folders,do_delete);
108 LIBMTP_Release_Device(device);