[Commits] [SCM] claws branch, master, updated. 3.13.0-10-ga04d186
claws at claws-mail.org
claws at claws-mail.org
Wed Oct 14 19:14:21 CEST 2015
The branch, master has been updated
via a04d186bb864e1fa0860fe48fa8084729dc3ce24 (commit)
from 7c605b01f430c497752c69a4ed8401dcc9cbc6f1 (commit)
Summary of changes:
src/plugins/mailmbox/mailimf_types_helper.c | 4 ++--
src/plugins/mailmbox/mailmbox.c | 2 +-
src/plugins/managesieve/sieve_prefs.c | 8 ++++----
src/plugins/rssyl/parse822.c | 2 +-
src/plugins/rssyl/rssyl_add_item.c | 2 +-
src/plugins/rssyl/rssyl_deleted.c | 7 ++++---
src/plugins/vcalendar/vcal_folder.c | 3 ++-
src/plugins/vcalendar/vcal_manager.c | 2 +-
src/plugins/vcalendar/vcal_meeting_gtk.c | 3 ++-
9 files changed, 18 insertions(+), 15 deletions(-)
- Log -----------------------------------------------------------------
commit a04d186bb864e1fa0860fe48fa8084729dc3ce24
Author: Paul <paul at claws-mail.org>
Date: Wed Oct 14 18:14:17 2015 +0100
fix format warnings and some OpenBSD specific fixes
Patch by Daniel Jakots.
diff --git a/src/plugins/mailmbox/mailimf_types_helper.c b/src/plugins/mailmbox/mailimf_types_helper.c
index 384e7a6..a0c4e96 100644
--- a/src/plugins/mailmbox/mailimf_types_helper.c
+++ b/src/plugins/mailmbox/mailimf_types_helper.c
@@ -1267,8 +1267,8 @@ char * mailimf_get_message_id(void)
value = random();
gethostname(name, MAX_MESSAGE_ID);
- snprintf(id, MAX_MESSAGE_ID, "etPan.%lx.%lx.%x@%s",
- now, value, getpid(), name);
+ snprintf(id, MAX_MESSAGE_ID, "etPan.%llx.%lx.%x@%s",
+ (long long)now, value, getpid(), name);
return strdup(id);
}
diff --git a/src/plugins/mailmbox/mailmbox.c b/src/plugins/mailmbox/mailmbox.c
index 1d0578d..f37c0e9 100644
--- a/src/plugins/mailmbox/mailmbox.c
+++ b/src/plugins/mailmbox/mailmbox.c
@@ -154,7 +154,7 @@ int claws_mailmbox_map(struct claws_mailmbox_folder * folder)
MAP_SHARED, folder->mb_fd, 0);
if (str == MAP_FAILED) {
perror("mmap");
- debug_print("map of %lu bytes failed\n", buf.st_size);
+ debug_print("map of %lld bytes failed\n", (long long)buf.st_size);
res = MAILMBOX_ERROR_FILE;
goto err;
}
diff --git a/src/plugins/managesieve/sieve_prefs.c b/src/plugins/managesieve/sieve_prefs.c
index c1c82d1..9976da7 100644
--- a/src/plugins/managesieve/sieve_prefs.c
+++ b/src/plugins/managesieve/sieve_prefs.c
@@ -464,7 +464,7 @@ struct SieveAccountConfig *sieve_prefs_account_get_config(
gchar enc_userid[256], enc_passwd[256];
gchar enable, use_host, use_port;
gsize len;
-#ifdef G_OS_WIN32
+#if defined(G_OS_WIN32) || defined(__OpenBSD__)
/* Windows sscanf() does not understand the %ms format yet, so we
* have to do the allocation of target buffer ourselves before
* calling sscanf(), and copy the host string to config->host.
@@ -489,13 +489,13 @@ struct SieveAccountConfig *sieve_prefs_account_get_config(
if (confstr == NULL)
return config;
-#ifdef G_OS_WIN32
+#if defined(G_OS_WIN32) || defined(__OpenBSD__)
sscanf(confstr, "%c%c %255s %c%hu %hhu %hhu %hhu %255s %255s",
#else
sscanf(confstr, "%c%c %ms %c%hu %hhu %hhu %hhu %255s %255s",
#endif
&enable, &use_host,
-#ifdef G_OS_WIN32
+#if defined(G_OS_WIN32) || defined(__OpenBSD__)
tmphost,
#else
&config->host,
@@ -507,7 +507,7 @@ struct SieveAccountConfig *sieve_prefs_account_get_config(
enc_userid,
enc_passwd);
-#ifdef G_OS_WIN32
+#if defined(G_OS_WIN32) || defined(__OpenBSD__)
config->host = g_strndup(tmphost, 255);
#endif
diff --git a/src/plugins/rssyl/parse822.c b/src/plugins/rssyl/parse822.c
index fa17f7b..ca8b842 100644
--- a/src/plugins/rssyl/parse822.c
+++ b/src/plugins/rssyl/parse822.c
@@ -135,7 +135,7 @@ FeedItem *rssyl_parse_folder_item_file(gchar *path)
/* Last-Seen timestamp */
if( !strcmp(line[0], "X-RSSyl-Last-Seen") ) {
ctx->last_seen = atol(line[1]);
- debug_print("RSSyl: got last_seen timestamp %ld\n", ctx->last_seen);
+ debug_print("RSSyl: got last_seen timestamp %lld\n", (long long)ctx->last_seen);
}
/* ID */
diff --git a/src/plugins/rssyl/rssyl_add_item.c b/src/plugins/rssyl/rssyl_add_item.c
index 342b28f..922ad4e 100644
--- a/src/plugins/rssyl/rssyl_add_item.c
+++ b/src/plugins/rssyl/rssyl_add_item.c
@@ -463,7 +463,7 @@ void rssyl_add_item(RFolderItem *ritem, FeedItem *feed_item)
fprintf(f, "X-RSSyl-URL: %s\n", tmpurl);
if( ritem->last_update > 0) {
- fprintf(f, "X-RSSyl-Last-Seen: %ld\n", ritem->last_update);
+ fprintf(f, "X-RSSyl-Last-Seen: %lld\n", (long long)ritem->last_update);
}
/* Message-ID */
diff --git a/src/plugins/rssyl/rssyl_deleted.c b/src/plugins/rssyl/rssyl_deleted.c
index 40328a0..7a4aabe 100644
--- a/src/plugins/rssyl/rssyl_deleted.c
+++ b/src/plugins/rssyl/rssyl_deleted.c
@@ -160,10 +160,11 @@ static void _store_one_deleted_item(gpointer data, gpointer user_data)
err |= (fprintf(f,
"ID: %s\n"
"TITLE: %s\n"
- "DPUB: %ld\n"
- "DMOD: %ld\n",
+ "DPUB: %lld\n"
+ "DMOD: %lld\n",
ditem->id, ditem->title,
- ditem->date_published, ditem->date_modified) < 0);
+ (long long)ditem->date_published,
+ (long long)ditem->date_modified) < 0);
if (err)
debug_print("RSSyl: Error during writing deletion file.\n");
diff --git a/src/plugins/vcalendar/vcal_folder.c b/src/plugins/vcalendar/vcal_folder.c
index a78c2dd..b02ee76 100644
--- a/src/plugins/vcalendar/vcal_folder.c
+++ b/src/plugins/vcalendar/vcal_folder.c
@@ -1161,7 +1161,8 @@ static void vcal_set_mtime(Folder *folder, FolderItem *item)
}
item->mtime = s.st_mtime;
- debug_print("VCAL: forced mtime of %s to %ld\n", item->name?item->name:"(null)", item->mtime);
+ debug_print("VCAL: forced mtime of %s to %lld\n",
+ item->name?item->name:"(null)", (long long)item->mtime);
g_free(path);
}
diff --git a/src/plugins/vcalendar/vcal_manager.c b/src/plugins/vcalendar/vcal_manager.c
index 5867514..1f11f26 100644
--- a/src/plugins/vcalendar/vcal_manager.c
+++ b/src/plugins/vcalendar/vcal_manager.c
@@ -920,7 +920,7 @@ void vcal_manager_save_event (VCalEvent *event, gboolean export_after)
xml_tag_add_attr(tag, xml_attr_new("type", tmp));
g_free(tmp);
- tmp = g_strdup_printf("%lu", event->postponed);
+ tmp = g_strdup_printf("%lld", (long long)event->postponed);
xml_tag_add_attr(tag, xml_attr_new("postponed", tmp));
g_free(tmp);
diff --git a/src/plugins/vcalendar/vcal_meeting_gtk.c b/src/plugins/vcalendar/vcal_meeting_gtk.c
index de0ce34..0b0e123 100644
--- a/src/plugins/vcalendar/vcal_meeting_gtk.c
+++ b/src/plugins/vcalendar/vcal_meeting_gtk.c
@@ -1962,7 +1962,8 @@ void multisync_export(void)
list = vcal_folder_get_waiting_events();
for (cur = list; cur; cur = cur->next) {
VCalEvent *event = (VCalEvent *)cur->data;
- file = g_strdup_printf("multisync%lu-%d", time(NULL), i);
+ file = g_strdup_printf("multisync%lld-%d",
+ (long long)time(NULL), i);
i++;
-----------------------------------------------------------------------
hooks/post-receive
--
Claws Mail
More information about the Commits
mailing list