diff options
author | Marcus Meissner <marcus@jet.franken.de> | 2009-01-25 20:30:53 +0000 |
---|---|---|
committer | Marcus Meissner <marcus@jet.franken.de> | 2009-01-25 20:30:53 +0000 |
commit | a3ee73043c5dc7c28b5717fd971917627a7214f2 (patch) | |
tree | 4249bb9b1b0debbe19c6df749f8d045bcc39a055 /camlibs/ricoh | |
parent | ccd327a379d7885389f57f0e8304c4cce948921f (diff) | |
download | libgphoto2-a3ee73043c5dc7c28b5717fd971917627a7214f2.tar.gz |
* removed CameraFileInfoFile.name, adjusted users
and callers.
* added filename argument to put_file_func,
set_info_noop and set_file_noop functions.
adjusted all camlibs
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@11773 67ed7778-7388-44ab-90cf-0a291f65f57c
Diffstat (limited to 'camlibs/ricoh')
-rw-r--r-- | camlibs/ricoh/g3.c | 8 | ||||
-rw-r--r-- | camlibs/ricoh/library.c | 12 |
2 files changed, 7 insertions, 13 deletions
diff --git a/camlibs/ricoh/g3.c b/camlibs/ricoh/g3.c index ce39a9f5d..a1e72edc1 100644 --- a/camlibs/ricoh/g3.c +++ b/camlibs/ricoh/g3.c @@ -422,20 +422,18 @@ out: * with it and sometimes refuses to send data the correct way */ static int -put_file_func (CameraFilesystem *fs, const char *folder, CameraFile *file, +put_file_func (CameraFilesystem *fs, const char *folder, const char *fn, CameraFile *file, void *data, GPContext *context) { Camera *camera = data; char *buf = NULL, *reply = NULL, *cmd =NULL; - const char *fn = NULL, *imgdata = NULL; + const char *imgdata = NULL; int ret, channel, len; long size; ret = g3_cwd_command (camera->port, folder); if (ret < GP_OK) goto out; - ret = gp_file_get_name (file, &fn); - if (ret < GP_OK) goto out; ret = gp_file_get_data_and_size (file, &imgdata, &size); if (ret < GP_OK) goto out; @@ -849,7 +847,7 @@ file_list_func (CameraFilesystem *fs, const char *folder, CameraList *list, ((year & 3) == 0 && month < 2 ? 1 : 0)+ 3653); - ret = gp_filesystem_set_info_noop(fs, folder, info, context); + ret = gp_filesystem_set_info_noop(fs, folder, xfn, info, context); } } diff --git a/camlibs/ricoh/library.c b/camlibs/ricoh/library.c index 8588f24d8..32623f7fd 100644 --- a/camlibs/ricoh/library.c +++ b/camlibs/ricoh/library.c @@ -277,19 +277,15 @@ camera_capture (Camera *camera, CameraCaptureType type, } static int -put_file_func (CameraFilesystem *fs, const char *folder, CameraFile *file, - void *user_data, GPContext *context) +put_file_func (CameraFilesystem *fs, const char *folder, const char *name, + CameraFile *file, void *user_data, GPContext *context) { - const char *data, *name; + const char *data; unsigned long int size; Camera *camera = user_data; CR (gp_file_get_data_and_size (file, &data, &size)); - CR (gp_file_get_name (file, &name)); - - CR (ricoh_put_file (camera, context, name, data, size)); - - return (GP_OK); + return ricoh_put_file (camera, context, name, data, size); } #undef N_ELEMENTS |