| 458 const char *start; |
458 const char *start; |
| 459 const char *end; |
459 const char *end; |
| 460 GData *attributes; |
460 GData *attributes; |
| 461 char *fontsize = NULL; |
461 char *fontsize = NULL; |
| 462 |
462 |
| 463 purple_markup_find_tag(tag_name, tag, &start, &end, &attributes); |
463 if (!purple_markup_find_tag(tag_name, tag, &start, &end, &attributes)) |
| |
464 g_return_if_reached(); |
| 464 *cur = xmlnode_new_child(*cur, tag_name); |
465 *cur = xmlnode_new_child(*cur, tag_name); |
| 465 |
466 |
| 466 if (is_font_tag) { |
467 if (is_font_tag) { |
| 467 /* Special case for the font size attribute */ |
468 /* Special case for the font size attribute */ |
| 468 fontsize = g_strdup(g_datalist_get_data(&attributes, "size")); |
469 fontsize = g_strdup(g_datalist_get_data(&attributes, "size")); |
| 736 GData *attributes; |
737 GData *attributes; |
| 737 const char *attribute; |
738 const char *attribute; |
| 738 gboolean needendtag; |
739 gboolean needendtag; |
| 739 GString *tmp; |
740 GString *tmp; |
| 740 |
741 |
| 741 purple_markup_find_tag(tag_name, tag, &start, &end, &attributes); |
742 if (!purple_markup_find_tag(tag_name, tag, &start, &end, &attributes)) |
| |
743 g_return_if_reached(); |
| 742 |
744 |
| 743 needendtag = FALSE; |
745 needendtag = FALSE; |
| 744 tmp = g_string_new(NULL); |
746 tmp = g_string_new(NULL); |
| 745 |
747 |
| 746 attribute = g_datalist_get_data(&attributes, "color"); |
748 attribute = g_datalist_get_data(&attributes, "color"); |
| 862 * complicated when dealing with HTML tags within the |
864 * complicated when dealing with HTML tags within the |
| 863 * <a> tag. |
865 * <a> tag. |
| 864 */ |
866 */ |
| 865 |
867 |
| 866 /* Append the URL */ |
868 /* Append the URL */ |
| 867 purple_markup_find_tag(tag_name, tag, &start, &end, &attributes); |
869 if (!purple_markup_find_tag(tag_name, |
| |
870 tag, &start, &end, &attributes)) |
| |
871 { |
| |
872 g_warn_if_reached(); |
| |
873 i = j; |
| |
874 g_free(tag); |
| |
875 g_free(tag_name); |
| |
876 break; |
| |
877 } |
| |
878 |
| 868 attribute = g_datalist_get_data(&attributes, "href"); |
879 attribute = g_datalist_get_data(&attributes, "href"); |
| 869 if (attribute != NULL) { |
880 if (attribute != NULL) { |
| 870 if (purple_str_has_prefix(attribute, "mailto:")) |
881 if (purple_str_has_prefix(attribute, "mailto:")) |
| 871 attribute += 7; |
882 attribute += 7; |
| 872 g_string_append(dest, attribute); |
883 g_string_append(dest, attribute); |