Simplify string duplication

Signed-off-by: OBATA Akio <obache@wizdas.com>
pull/3/head
OBATA Akio 4 years ago
parent 5c66fbf273
commit c4f584b28d

@ -147,7 +147,7 @@ static gchar* carddav_dirlist(carddav_settings* settings, carddav_error* error)
href = get_tag("d:href", tmp_report); href = get_tag("d:href", tmp_report);
} }
pos = strstr(tmp_report, href); pos = strstr(tmp_report, href);
all_href = g_strdup_printf(""); all_href = g_strdup("");
while ((href != NULL) && (pos != NULL)) { while ((href != NULL) && (pos != NULL)) {
href = get_tag(ELEM_HREF, pos); href = get_tag(ELEM_HREF, pos);
/* Maybe namespace prefixed */ /* Maybe namespace prefixed */

Loading…
Cancel
Save