+2006-06-19 [colin] 2.3.0cvs23
+
+ * src/compose.c
+ * src/imap.c
+ * src/etpan/imap-thread.c
+ Probably fix bug #972 (Freezes when adding
+ an attachment to the message)
+ * src/common/defs.h
+ Modernize Firefox cmd
+
+
2006-06-18 [colin] 2.3.0cvs22
* src/prefs_customheader.c
( cvs diff -u -r 1.79.2.35 -r 1.79.2.36 src/mh.c; ) > 2.3.0cvs20.patchset
( cvs diff -u -r 1.16.2.19 -r 1.16.2.20 src/prefs_customheader.c; ) > 2.3.0cvs21.patchset
( cvs diff -u -r 1.16.2.20 -r 1.16.2.21 src/prefs_customheader.c; ) > 2.3.0cvs22.patchset
+( cvs diff -u -r 1.382.2.279 -r 1.382.2.280 src/compose.c; cvs diff -u -r 1.179.2.120 -r 1.179.2.121 src/imap.c; cvs diff -u -r 1.9.2.25 -r 1.9.2.26 src/common/defs.h; cvs diff -u -r 1.1.4.40 -r 1.1.4.41 src/etpan/imap-thread.c; ) > 2.3.0cvs23.patchset
MICRO_VERSION=0
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=22
+EXTRA_VERSION=23
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=
/* #define DEFAULT_INC_PATH "/usr/bin/imget" */
/* #define DEFAULT_INC_PROGRAM "imget" */
#define DEFAULT_SENDMAIL_CMD "/usr/sbin/sendmail -t -i"
-#define DEFAULT_BROWSER_CMD "mozilla-firefox -remote 'openURL(%s,new-window)'"
-#define DEFAULT_EDITOR_CMD "gedit %s"
+#define DEFAULT_BROWSER_CMD "firefox '%s'"
+#define DEFAULT_EDITOR_CMD "gedit '%s'"
#define DEFAULT_MIME_CMD "metamail -d -b -x -c %s '%s'"
#define DEFAULT_IMAGE_VIEWER_CMD "display '%s'"
#define DEFAULT_AUDIO_PLAYER_CMD "play '%s'"
goto unlock;
}
g_free(tmp);
- draft->mtime = 0; /* force updating */
if (compose->mode == COMPOSE_REEDIT) {
compose_remove_reedit_target(compose, TRUE);
free(buf);
}
+void imap_logger_append(int direction, const char * str, size_t size)
+{
+ gchar *buf;
+ gchar **lines;
+ int i = 0;
+
+ buf = malloc(size+1);
+ memset(buf, 0, size+1);
+ strncpy(buf, str, size);
+ buf[size] = '\0';
+ if (!strncmp(buf, "<<<<<<<", 7)
+ || !strncmp(buf, ">>>>>>>", 7)) {
+ free(buf);
+ return;
+ }
+ while (strstr(buf, "\r"))
+ *strstr(buf, "\r") = ' ';
+ while (strlen(buf) > 0 && buf[strlen(buf)-1] == '\n')
+ buf[strlen(buf)-1] = '\0';
+
+ lines = g_strsplit(buf, "\n", -1);
+
+ if (direction == 0 || (buf[0] == '*' && buf[1] == ' ') || size < 32) {
+ while (lines[i] && *lines[i]) {
+ log_print("IMAP4%c %s\n", direction?'>':'<', lines[i]);
+ i++;
+ }
+ } else {
+ log_print("IMAP4%c [data - %zd bytes]\n", direction?'>':'<', size);
+ }
+ g_strfreev(lines);
+ free(buf);
+}
+
#define ETPAN_DEFAULT_NETWORK_TIMEOUT 60
static gboolean etpan_skip_ssl_cert_check = FALSE;
return;
}
+ mailstream_logger = imap_logger_append;
+
r = mailimap_append(param->imap, param->mailbox,
param->flag_list, NULL,
data, size/*, &uid */);
+
+ mailstream_logger = imap_logger_cmd;
munmap(data, size);
close(fd);
if (cached)
debug_print("message %d has been already %scached (%d/%d).\n", uid,
- have_size == cached->size ? "fully ":"",
+ have_size >= cached->size ? "fully ":"",
have_size, (int)cached->size);
- if (cached && (cached->size == have_size || !body)) {
+ if (cached && (cached->size <= have_size || !body)) {
procmsg_msginfo_free(cached);
procmsg_msginfo_free(msginfo);
file_strip_crs(filename);
if (new_uid == 0) {
new_uid = dest->last_num+1;
}
- if (last_uid < new_uid)
+ if (last_uid < new_uid) {
last_uid = new_uid;
+ }
g_free(real_file);
}
else {
*old_uids_valid = FALSE;
- debug_print("Freeing imap uid cache\n");
+ debug_print("Freeing imap uid cache (%d != %d)\n",
+ item->item.mtime, uid_val);
item->lastuid = 0;
g_slist_free(item->uid_list);
item->uid_list = NULL;