CVS: sylpheedclaws/sylpheed-claws/src prefs_account.c,1.105.2.71,1.105.2.72

[email protected] Mon, 11 Dec 2006 17:55:34 +0000
Newsgroups gmane.mail.sylpheed.claws.cvs
Message-ID <[email protected]>
Update of /pack/anoncvs/sylpheedclaws/sylpheed-claws/src
In directory sunsite.dk:/tmp/cvs-serv27665/src

Modified Files:
      Tag: gtk2
	prefs_account.c 
Log Message:
2006-12-11 [colin]	2.6.1cvs15

	* src/prefs_account.c
		Prevent use of non-existing default inbox

Index: prefs_account.c
===================================================================
RCS file: /pack/anoncvs/sylpheedclaws/sylpheed-claws/src/prefs_account.c,v
retrieving revision 1.105.2.71
retrieving revision 1.105.2.72
diff -u -d -r1.105.2.71 -r1.105.2.72
--- prefs_account.c	2006/12/11 17:23:54	1.105.2.71
+++ prefs_account.c	2006/12/11 17:55:28	1.105.2.72
@@ -2521,6 +2521,14 @@
 		alertpanel_error(_("POP3 server is not entered."));
 		return -1;
 	}
+	if (protocol == A_POP3) {
+		const gchar *mailbox = gtk_entry_get_text(GTK_ENTRY(receive.inbox_entry));
+		FolderItem *inbox =  folder_find_item_from_identifier(mailbox);
+	    	if (inbox == NULL) {
+			alertpanel_error(_("The default inbox folder doesn't exist."));
+			return -1;
+		}
+	}
 	if (protocol == A_IMAP4 &&
 	    *gtk_entry_get_text(GTK_ENTRY(basic.recvserv_entry)) == '\0') {
 		alertpanel_error(_("IMAP4 server is not entered."));