1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-12-04 14:46:47 -05:00

Utilise mem_free_set.

This commit is contained in:
Miciah Dashiel Butler Masters 2006-06-06 03:06:47 +00:00 committed by Miciah Dashiel Butler Masters
parent 551ff4587a
commit 1a3c8734d4

View File

@ -410,8 +410,7 @@ update_bookmark(struct bookmark *bm, unsigned char *title,
trigger_event(update_bookmark_event_id, bm, title2, url2); trigger_event(update_bookmark_event_id, bm, title2, url2);
if (title2) { if (title2) {
mem_free(bm->title); mem_free_set(&bm->title, title2);
bm->title = title2;
} }
if (url2) { if (url2) {
@ -427,8 +426,7 @@ update_bookmark(struct bookmark *bm, unsigned char *title,
add_hash_item(bookmark_cache, url2, strlen(url2), bm); add_hash_item(bookmark_cache, url2, strlen(url2), bm);
} }
mem_free(bm->url); mem_free_set(&bm->url, url2);
bm->url = url2;
} }
bookmarks_set_dirty(); bookmarks_set_dirty();