Changeset b4f496e for storage_xml.c
- Timestamp:
- 2016-11-19T07:32:48Z (8 years ago)
- Branches:
- master
- Children:
- a7baf40
- Parents:
- 9f03c47
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
storage_xml.c
r9f03c47 rb4f496e 60 60 } 61 61 62 static void handle_settings(struct xt_node *node, set_t **head )62 static void handle_settings(struct xt_node *node, set_t **head, gboolean add_unknowns) 63 63 { 64 64 struct xt_node *c; … … 70 70 71 71 if (!name) { 72 continue; 73 } 74 75 if (add_unknowns && !set_find(head, name)) { 76 s = set_add(head, name, NULL, NULL, NULL); 77 s->flags |= ACC_SET_ONLINE_ONLY; 78 s->value = g_strdup(c->text); 72 79 continue; 73 80 } … … 99 106 account_t *acc; 100 107 struct xt_node *c; 108 gboolean is_unknown = FALSE; 101 109 102 110 handle = xt_find_attr(node, "handle"); … … 111 119 prpl = find_protocol(protocol); 112 120 if (!prpl) { 113 irc_rootmsg(xd->irc, "Error loading user config: Protocol not found: `%s'", protocol); 114 return XT_ABORT; 115 } 121 irc_rootmsg(xd->irc, "Warning: Protocol not found: `%s'", protocol); 122 prpl = make_unknown_protocol(protocol); 123 } 124 is_unknown = (prpl->options & PRPL_OPT_UNKNOWN_PROTOCOL) != 0; 116 125 local = protocol_account_islocal(protocol); 117 126 } … … 153 162 g_free(password); 154 163 155 handle_settings(node, &acc->set );164 handle_settings(node, &acc->set, is_unknown); 156 165 157 166 for (c = node->children; (c = xt_find_node(c, "buddy")); c = c->next) { … … 192 201 } 193 202 194 handle_settings(node, &ic->set );203 handle_settings(node, &ic->set, FALSE); 195 204 196 205 return XT_HANDLED; … … 270 279 } 271 280 272 handle_settings(node, &xd->irc->b->set );281 handle_settings(node, &xd->irc->b->set, FALSE); 273 282 274 283 error:
Note: See TracChangeset
for help on using the changeset viewer.