| OLD | NEW |
| 1 /** | 1 /** |
| 2 * \file libmtp.c | 2 * \file libmtp.c |
| 3 * | 3 * |
| 4 * Copyright (C) 2005-2011 Linus Walleij <triad@df.lth.se> | 4 * Copyright (C) 2005-2011 Linus Walleij <triad@df.lth.se> |
| 5 * Copyright (C) 2005-2008 Richard A. Low <richard@wentnet.com> | 5 * Copyright (C) 2005-2008 Richard A. Low <richard@wentnet.com> |
| 6 * Copyright (C) 2007 Ted Bullock <tbullock@canada.com> | 6 * Copyright (C) 2007 Ted Bullock <tbullock@canada.com> |
| 7 * Copyright (C) 2007 Tero Saarni <tero.saarni@gmail.com> | 7 * Copyright (C) 2007 Tero Saarni <tero.saarni@gmail.com> |
| 8 * Copyright (C) 2008 Florent Mertens <flomertens@gmail.com> | 8 * Copyright (C) 2008 Florent Mertens <flomertens@gmail.com> |
| 9 * | 9 * |
| 10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
| (...skipping 2339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2350 PTP_USB *ptp_usb = (PTP_USB*) device->usbinfo; | 2350 PTP_USB *ptp_usb = (PTP_USB*) device->usbinfo; |
| 2351 | 2351 |
| 2352 close_device(ptp_usb, params); | 2352 close_device(ptp_usb, params); |
| 2353 // Clear error stack | 2353 // Clear error stack |
| 2354 LIBMTP_Clear_Errorstack(device); | 2354 LIBMTP_Clear_Errorstack(device); |
| 2355 // Free iconv() converters... | 2355 // Free iconv() converters... |
| 2356 iconv_close(params->cd_locale_to_ucs2); | 2356 iconv_close(params->cd_locale_to_ucs2); |
| 2357 iconv_close(params->cd_ucs2_to_locale); | 2357 iconv_close(params->cd_ucs2_to_locale); |
| 2358 free(ptp_usb); | 2358 free(ptp_usb); |
| 2359 ptp_free_params(params); | 2359 ptp_free_params(params); |
| 2360 free(params); |
| 2360 free_storage_list(device); | 2361 free_storage_list(device); |
| 2361 // Free extension list... | 2362 // Free extension list... |
| 2362 if (device->extensions != NULL) { | 2363 if (device->extensions != NULL) { |
| 2363 LIBMTP_device_extension_t *tmp = device->extensions; | 2364 LIBMTP_device_extension_t *tmp = device->extensions; |
| 2364 | 2365 |
| 2365 while (tmp != NULL) { | 2366 while (tmp != NULL) { |
| 2366 LIBMTP_device_extension_t *next = tmp->next; | 2367 LIBMTP_device_extension_t *next = tmp->next; |
| 2367 | 2368 |
| 2368 if (tmp->name) | 2369 if (tmp->name) |
| 2369 free(tmp->name); | 2370 free(tmp->name); |
| (...skipping 6576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8946 * @param device the device which may have a cache to which the object should be
updated. | 8947 * @param device the device which may have a cache to which the object should be
updated. |
| 8947 * @param object_id the object to update. | 8948 * @param object_id the object to update. |
| 8948 */ | 8949 */ |
| 8949 static void update_metadata_cache(LIBMTP_mtpdevice_t *device, uint32_t object_id
) | 8950 static void update_metadata_cache(LIBMTP_mtpdevice_t *device, uint32_t object_id
) |
| 8950 { | 8951 { |
| 8951 PTPParams *params = (PTPParams *)device->params; | 8952 PTPParams *params = (PTPParams *)device->params; |
| 8952 | 8953 |
| 8953 ptp_remove_object_from_cache(params, object_id); | 8954 ptp_remove_object_from_cache(params, object_id); |
| 8954 add_object_to_cache(device, object_id); | 8955 add_object_to_cache(device, object_id); |
| 8955 } | 8956 } |
| OLD | NEW |