1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-09-28 03:06:20 -04:00

look_for_link: simplify string

Use stracpy(empty_string_or_(target_base)) instead of
null_or_stracpy(target_base) and then stracpy("") if that returns NULL.
This commit is contained in:
Miciah Dashiel Butler Masters 2006-01-18 20:38:33 +00:00 committed by Jonas Fonseca
parent a191b4dc31
commit 2cab7a5455

View File

@ -533,8 +533,7 @@ look_for_link(unsigned char **pos, unsigned char *eof, struct menu_item **menu,
}
target = get_target(options, attr);
if (!target) target = null_or_stracpy(target_base);
if (!target) target = stracpy("");
if (!target) target = stracpy(empty_string_or_(target_base));
if (!target) {
mem_free_if(label);
return 1;