From 6ac4ceb4c6ee63c279f4841381a3eb09598f3517 Mon Sep 17 00:00:00 2001 From: Jonathan Beck Date: Mon, 25 Aug 2008 23:25:56 +0200 Subject: migrate main.c --- src/ifuse.c | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) (limited to 'src/ifuse.c') diff --git a/src/ifuse.c b/src/ifuse.c index 7672bb9..cc2072f 100644 --- a/src/ifuse.c +++ b/src/ifuse.c @@ -42,8 +42,8 @@ GHashTable *file_handles; int fh_index = 0; -iPhone *phone = NULL; -lockdownd_client *control = NULL; +iphone_device_t phone = NULL; +iphone_lckd_client_t control = NULL; int debug = 0; @@ -52,22 +52,6 @@ static int ifuse_getattr(const char *path, struct stat *stbuf) { AFCFile *file; AFClient *afc = fuse_get_context()->private_data; - memset(stbuf, 0, sizeof(struct stat)); - file = afc_get_file_info(afc, path); - if (!file){ - res = -ENOENT; - } else { - stbuf->st_mode = file->type | (S_ISDIR(file->type) ? 0755 : 0644); - stbuf->st_size = file->size; - stbuf->st_blksize = 2048; // FIXME: Is this the actual block size used on the iPhone? - stbuf->st_blocks = file->blocks; - stbuf->st_uid = getuid(); - stbuf->st_gid = getgid(); - - afc_close_file(afc,file); - free(file); - } - return res; } -- cgit v1.1-32-gdbae