brasero r592 - in trunk: . src/plugins/growisofs



Author: lmedinas
Date: Tue Jan 15 01:30:18 2008
New Revision: 592
URL: http://svn.gnome.org/viewvc/brasero?rev=592&view=rev

Log:
2008-01-15  Luis Medinas  <lmedinas svn gnome org>

        * src/plugins/growisofs/burn-growisofs.c:
        (brasero_growisofs_init):

        Added a workaround to use genisoimage if it's available
        if not will use mkisofs.


Modified:
   trunk/ChangeLog
   trunk/src/plugins/growisofs/burn-growisofs.c

Modified: trunk/src/plugins/growisofs/burn-growisofs.c
==============================================================================
--- trunk/src/plugins/growisofs/burn-growisofs.c	(original)
+++ trunk/src/plugins/growisofs/burn-growisofs.c	Tue Jan 15 01:30:18 2008
@@ -592,16 +592,20 @@
 	BraseroGrowisofsPrivate *priv;
 	gchar *standard_error;
 	gboolean res;
+	gchar *prog_name;
 
 	priv = BRASERO_GROWISOFS_PRIVATE (obj);
 
 	/* this code comes from ncb_mkisofs_supports_utf8 */
-	res = g_spawn_command_line_sync ("mkisofs -input-charset utf8", 
-					 NULL,
-					 &standard_error,
-					 NULL, 
-					 NULL);
-	if (res && !g_strrstr (standard_error, "Unknown charset"))
+	
+	prog_name = g_find_program_in_path ("genisoimage");
+        if (prog_name && g_file_test (prog_name, G_FILE_TEST_IS_EXECUTABLE)) {
+	  	res = g_spawn_command_line_sync ("genisoimage -input-charset utf8", NULL, &standard_error, NULL, NULL);
+	} else {
+                res = g_spawn_command_line_sync ("mkisofs -input-charset utf8", NULL, &standard_error, NULL, NULL);
+	}
+
+       	if (res && !g_strrstr (standard_error, "Unknown charset"))
 		priv->use_utf8 = TRUE;
 	else
 		priv->use_utf8 = FALSE;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]