Revision: 1495
          http://geeqie.svn.sourceforge.net/geeqie/?rev=1495&view=rev
Author:   zas_
Date:     2009-03-08 15:02:18 +0000 (Sun, 08 Mar 2009)

Log Message:
-----------
Fix up editor execution.

Modified Paths:
--------------
    trunk/src/editors.c

Modified: trunk/src/editors.c
===================================================================
--- trunk/src/editors.c 2009-03-08 14:27:19 UTC (rev 1494)
+++ trunk/src/editors.c 2009-03-08 15:02:18 UTC (rev 1495)
@@ -688,28 +688,30 @@
                                                flags |= 
EDITOR_ERROR_INCOMPATIBLE;
                                                goto err;
                                                }
-                                       /* use the first file from the list */
-                                       if (!list || !list->data)
+                                       if (list)
                                                {
-                                               flags |= EDITOR_ERROR_NO_FILE;
-                                               goto err;
+                                               /* use the first file from the 
list */
+                                               if (!list->data)
+                                                       {
+                                                       flags |= 
EDITOR_ERROR_NO_FILE;
+                                                       goto err;
+                                                       }
+                                               pathl = 
editor_command_path_parse((FileData *)list->data,
+                                                                               
  (*p == 'f') ? PATH_FILE : PATH_FILE_URL,
+                                                                               
  editor);
+                                               if (!pathl)
+                                                       {
+                                                       flags |= 
EDITOR_ERROR_NO_FILE;
+                                                       goto err;
+                                                       }
+                                               if (output)
+                                                       {
+                                                       result = 
g_string_append_c(result, '"');
+                                                       result = 
g_string_append(result, pathl);
+                                                       result = 
g_string_append_c(result, '"');
+                                                       }
+                                               g_free(pathl);
                                                }
-                                       pathl = 
editor_command_path_parse((FileData *)list->data,
-                                                                         (*p 
== 'f') ? PATH_FILE : PATH_FILE_URL,
-                                                                         
editor);
-                                       if (!pathl)
-                                               {
-                                               flags |= EDITOR_ERROR_NO_FILE;
-                                               goto err;
-                                               }
-                                       if (output)
-                                               {
-                                               result = 
g_string_append_c(result, '"');
-                                               result = 
g_string_append(result, pathl);
-                                               result = 
g_string_append_c(result, '"');
-                                               }
-                                       g_free(pathl);
-
                                        break;
 
                                case 'F':
@@ -721,6 +723,7 @@
                                                goto err;
                                                }
 
+                                       if (list)
                                                {
                                                /* use whole list */
                                                GList *work = list;


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geeqie-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geeqie-svn

Reply via email to