diff finch/libgnt/gntfilesel.c @ 24558:e2e57d3c0578

Use glib log functions to show error messages.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 28 Nov 2008 06:29:37 +0000
parents 0ba0f2804299
children 89644e8d4323
line wrap: on
line diff
--- a/finch/libgnt/gntfilesel.c	Fri Nov 28 02:58:00 2008 +0000
+++ b/finch/libgnt/gntfilesel.c	Fri Nov 28 06:29:37 2008 +0000
@@ -20,6 +20,10 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02111-1301  USA
  */
 
+#include "gntinternal.h"
+#undef GNT_LOG_DOMAIN
+#define GNT_LOG_DOMAIN "FileSel"
+
 #include "gntbutton.h"
 #include "gntentry.h"
 #include "gntfilesel.h"
@@ -254,7 +258,7 @@
 		struct stat st;
 
 		if (stat(fp, &st)) {
-			g_printerr("Error stating location %s\n", fp);
+			gnt_warning("Error stating location %s", fp);
 		} else {
 			if (S_ISDIR(st.st_mode)) {
 				file = gnt_file_new_dir(str);
@@ -309,7 +313,7 @@
 		success = local_read_fn(sel->current, &files, err);
 	
 	if (!success || *err) {
-		g_printerr("GntFileSel: error opening location %s (%s)\n",
+		gnt_warning("error opening location %s (%s)",
 			sel->current, *err ? (*err)->message : "reason unknown");
 		return FALSE;
 	}