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

Drop useless goto/label.

This commit is contained in:
Laurent MONIN 2007-09-14 09:26:39 +02:00 committed by Witold Filipczyk
parent 942fde534d
commit ed21e3275c

View File

@ -2213,30 +2213,27 @@ ret:
/* Clear memory to prevent bad key comparaison due to alignment /* Clear memory to prevent bad key comparaison due to alignment
* of key fields. */ * of key fields. */
struct table_cache_entry *tce = mem_calloc(1, sizeof(*tce)); struct table_cache_entry *tce = mem_calloc(1, sizeof(*tce));
/* A goto is used here to prevent a test or code
* redundancy. */
if (!tce) goto end;
tce->key.start = start; if (tce) {
tce->key.end = end; tce->key.start = start;
tce->key.align = align; tce->key.end = end;
tce->key.margin = margin; tce->key.align = align;
tce->key.width = width; tce->key.margin = margin;
tce->key.x = x; tce->key.width = width;
tce->key.link_num = link_num; tce->key.x = x;
copy_struct(&tce->part, part); tce->key.link_num = link_num;
copy_struct(&tce->part, part);
if (!add_hash_item(table_cache, if (!add_hash_item(table_cache,
(unsigned char *) &tce->key, (unsigned char *) &tce->key,
sizeof(tce->key), tce)) { sizeof(tce->key), tce)) {
mem_free(tce); mem_free(tce);
} else { } else {
table_cache_entries++; table_cache_entries++;
}
} }
} }
end:
return part; return part;
} }