diff options
author | Dan Winship <danw@src.gnome.org> | 2001-09-11 06:48:52 +0800 |
---|---|---|
committer | Dan Winship <danw@src.gnome.org> | 2001-09-11 06:48:52 +0800 |
commit | fb1c9fcb9b5b400ba0b94e942e8033b66d6c3162 (patch) | |
tree | 7291c70eb42ef7480885bc968023478ae2a0685f /my-evolution/e-summary-rdf.c | |
parent | b5297de4c44a76856bd3e0385bd8ba36a40c18d1 (diff) | |
download | gsoc2013-evolution-fb1c9fcb9b5b400ba0b94e942e8033b66d6c3162.tar.gz gsoc2013-evolution-fb1c9fcb9b5b400ba0b94e942e8033b66d6c3162.tar.zst gsoc2013-evolution-fb1c9fcb9b5b400ba0b94e942e8033b66d6c3162.zip |
Purification.
* e-summary.c (destroy): free the protocol hash.
* e-summary-rdf.c (tree_walk): plug a leak.
* e-summary-weather.c (e_summary_weather_init_locations): Don't
insert duplicates into the hash table.
* e-summary-mail.c (e_summary_mail_generate_html): free old html
before setting new
* e-summary.c (e_summary_draw): free weather and rdf html strings.
* e-summary-preferences.c (save_known_rdfs): free strings.
svn path=/trunk/; revision=12747
Diffstat (limited to 'my-evolution/e-summary-rdf.c')
-rw-r--r-- | my-evolution/e-summary-rdf.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/my-evolution/e-summary-rdf.c b/my-evolution/e-summary-rdf.c index 24c8de3cc6..abc4f918c3 100644 --- a/my-evolution/e-summary-rdf.c +++ b/my-evolution/e-summary-rdf.c @@ -116,17 +116,17 @@ layer_find_url (xmlNodePtr node, if (*r == ' ') r++; /* Fix UF bug */ while (*r) { - if (memcmp (r, "&", 5) == 0) { + if (strncmp (r, "&", 5) == 0) { *w++ = '&'; r += 5; continue; } - if (memcmp (r, "<", 4) == 0) { + if (strncmp (r, "<", 4) == 0) { *w++ = '<'; r += 4; continue; } - if (memcmp (r, ">", 4) == 0) { + if (strncmp (r, ">", 4) == 0) { *w++ = '>'; r += 4; continue; @@ -229,12 +229,8 @@ tree_walk (xmlNodePtr root, t = layer_find(channel->childs, "title", ""); u = layer_find(channel->childs, "link", ""); - if (*u != '\0') { - char *full; - - full = g_strdup_printf ("<a href=\"%s\">", u); - g_string_append (html, full); - } + if (*u != '\0') + g_string_sprintfa (html, "<a href=\"%s\">", u); t = e_utf8_from_locale_string (t); g_string_append (html, t); g_free (t); |