david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

[mucurses] Ensure SLK labels are always terminated

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown 2017-03-22 16:35:29 +02:00
parent 3870a7bde2
commit f032556b15
1 changed files with 1 additions and 1 deletions

View File

@ -359,7 +359,7 @@ int slk_set ( int labnum, const char *label, int fmt ) {
return ERR;
strncpy(slks->fkeys[labnum].label, label,
sizeof(slks->fkeys[labnum].label));
(sizeof(slks->fkeys[labnum].label) - 1));
slks->fkeys[labnum].fmt = fmt;
return OK;