Enlightenment CVS committal Author : lordchaos Project : e17 Module : apps/evfs
Dir : e17/apps/evfs/src/common Modified Files: evfs_event_helper.c evfs_io.c Log Message: * Create the concept of an 'evfs_stat', because 'struct stat' cannot be portably transmitted between processes (because of byte-alignment) * Checkin latest version of John Kha's FTP plugin. Note that there are still some issues with directory listing here. =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/common/evfs_event_helper.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -3 -r1.8 -r1.9 --- evfs_event_helper.c 22 Oct 2005 04:51:42 -0000 1.8 +++ evfs_event_helper.c 9 Nov 2005 23:51:05 -0000 1.9 @@ -29,7 +29,15 @@ evfs_event* event = NEW(evfs_event); event->type = EVFS_EV_STAT; - memcpy(&event->stat.stat_obj, stat_obj, sizeof(struct stat)); + + //memcpy(&event->stat.stat_obj, stat_obj, sizeof(struct stat)); + event->stat.stat_obj.st_uid = stat_obj->st_uid; + event->stat.stat_obj.st_gid = stat_obj->st_gid; + event->stat.stat_obj.st_uid = stat_obj->st_uid; + event->stat.stat_obj.st_size = stat_obj->st_size; + event->stat.stat_obj.ist_atime = stat_obj->st_atime; + event->stat.stat_obj.ist_mtime = stat_obj->st_mtime; + event->stat.stat_obj.ist_ctime = stat_obj->st_ctime; evfs_write_event(client, command, event); =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/common/evfs_io.c,v retrieving revision 1.26 retrieving revision 1.27 diff -u -3 -r1.26 -r1.27 --- evfs_io.c 9 Nov 2005 11:26:40 -0000 1.26 +++ evfs_io.c 9 Nov 2005 23:51:05 -0000 1.27 @@ -72,7 +72,8 @@ } void evfs_write_stat_event (evfs_client* client, evfs_event* event) { - evfs_write_ecore_ipc_client_message(client->client, ecore_ipc_message_new(EVFS_EV_REPLY,EVFS_EV_PART_STAT_SIZE,client->id,0,0,&event->stat.stat_obj,sizeof(struct stat))); + evfs_write_ecore_ipc_client_message(client->client, ecore_ipc_message_new(EVFS_EV_REPLY,EVFS_EV_PART_STAT_SIZE,client->id,0,0,&event->stat.stat_obj,sizeof(evfs_stat))); + } @@ -91,6 +92,7 @@ memcpy(block+sizeof(evfs_file_type), ref->path, strlen(ref->path)+1);*/ data =eet_data_descriptor_encode(_evfs_filereference_edd, ref, &size_ret); + printf("Encoded filename: '%s'\n", ref->path); /*printf ("Writing filename '%s' with filetype %d\n", ref->path, ref->file_type);*/ evfs_write_ecore_ipc_client_message(client->client, ecore_ipc_message_new(EVFS_EV_REPLY,EVFS_EV_PART_FILE_REFERENCE,client->id,0,0,data, size_ret )); @@ -149,7 +151,9 @@ break; case EVFS_EV_PART_STAT_SIZE: - memcpy(&event->stat.stat_obj, msg->data, sizeof(struct stat)); + + memcpy(&event->stat.stat_obj, msg->data, sizeof(evfs_stat)); + break; case EVFS_EV_PART_FILE_REFERENCE: { @@ -159,11 +163,16 @@ event->file_list.list = ecore_list_new(); //printf("Created new ecore list at %p\n", event->file_list.list); } + ref = eet_data_descriptor_decode(_evfs_filereference_edd, msg->data, msg->len); - - ecore_list_append(event->file_list.list, ref); + + if (ref) { + ecore_list_append(event->file_list.list, ref); + } else { + printf("Error decoding eet!\n"); } + } break; ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs