aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-account.c
diff options
context:
space:
mode:
Diffstat (limited to 'e-util/e-account.c')
-rw-r--r--e-util/e-account.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/e-util/e-account.c b/e-util/e-account.c
index c899170e58..37132017f0 100644
--- a/e-util/e-account.c
+++ b/e-util/e-account.c
@@ -282,6 +282,22 @@ xml_set_identity (xmlNodePtr node, EAccountIdentity *id)
changed |= xml_set_content (node, &id->organization);
else if (!strcmp (node->name, "signature")) {
changed |= xml_set_prop (node, "uid", &id->sig_uid);
+ if (!id->sig_uid) {
+ /* set a fake sig uid so the migrate code can handle this */
+ gboolean autogen = FALSE;
+ int sig_id = 0;
+
+ xml_set_bool (node, "auto", &autogen);
+ xml_set_int (node, "default", &sig_id);
+
+ if (autogen) {
+ id->sig_uid = g_strdup ("::0");
+ changed = TRUE;
+ } else if (sig_id) {
+ id->sig_uid = g_strdup_printf ("::%d", sig_id + 1);
+ changed = TRUE;
+ }
+ }
}
}