forked from enlightenment/efl
elm naviframe - fix buffer size handling and strncat
strncat where the size passed is tghe size of the string is pointless. it is strcat. so chekc before the strcat... and be simpler and honest
This commit is contained in:
parent
927bd2a656
commit
603adee731
|
@ -517,7 +517,8 @@ _elm_naviframe_item_elm_widget_item_part_text_set(Eo *eo_it,
|
|||
strncat(buf, nit->title_label, sizeof(buf) - 1);
|
||||
if (nit->subtitle_label)
|
||||
{
|
||||
if (nit->title_label) strncat(buf, " ", 1);
|
||||
if ((nit->title_label) && (strlen(buf) < (sizeof(buf) - 2)))
|
||||
strcat(buf, " ");
|
||||
strncat(buf, nit->subtitle_label, sizeof(buf) - strlen(buf) - 2);
|
||||
}
|
||||
efl_access_object_i18n_name_set(eo_it, buf);
|
||||
|
|
Loading…
Reference in New Issue