Enlightenment CVS committal Author : chaos Project : e17 Module : apps/evfs
Dir : e17/apps/evfs/src/bin Modified Files: evfs_server_handle.c Log Message: * Additional check =================================================================== RCS file: /cvs/e/e17/apps/evfs/src/bin/evfs_server_handle.c,v retrieving revision 1.64 retrieving revision 1.65 diff -u -3 -r1.64 -r1.65 --- evfs_server_handle.c 6 Aug 2006 09:56:27 -0000 1.64 +++ evfs_server_handle.c 6 Aug 2006 10:00:34 -0000 1.65 @@ -404,6 +404,21 @@ return; } + if (num_files > 2) { + dst_plugin = + evfs_get_plugin_for_uri(client->server, + command->file_command.files[num_files-1]->plugin_uri); + + /*Check if >2 files, dest file is a dir*/ + res = + (*EVFS_PLUGIN_FILE(dst_plugin)->functions->evfs_file_lstat) (command, &dest_stat, num_files-1); + + if (res != EVFS_SUCCESS || !S_ISDIR(dest_stat.st_mode)) { + printf("Copy > 2 files, and dest is not a directory\n"); + return; + } + } + /*Make a new evfs_operation, for client communication */ if (root_command == command) { op = evfs_operation_files_new(client, root_command); @@ -417,10 +432,6 @@ evfs_get_plugin_for_uri(client->server, command->file_command.files[c_file]->plugin_uri); - dst_plugin = - evfs_get_plugin_for_uri(client->server, - command->file_command.files[num_files-1]->plugin_uri); - if (plugin && dst_plugin) { /*Check for supported options */ ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs