summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Brown2017-03-21 13:37:53 +0100
committerMichael Brown2017-03-21 13:37:53 +0100
commitd29e2d551c3778066ee94c868850ec1e8ab17c81 (patch)
tree6b8f1af2207a751094d24b6d871ed4b9027ccdd8
parent[usb] Use correct length for memcpy() (diff)
downloadipxe-d29e2d551c3778066ee94c868850ec1e8ab17c81.tar.gz
ipxe-d29e2d551c3778066ee94c868850ec1e8ab17c81.tar.xz
ipxe-d29e2d551c3778066ee94c868850ec1e8ab17c81.zip
[mucurses] Attempt to fix test for empty string
Signed-off-by: Michael Brown <mcb30@ipxe.org>
-rw-r--r--src/hci/mucurses/slk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hci/mucurses/slk.c b/src/hci/mucurses/slk.c
index 660eb65c..da35c567 100644
--- a/src/hci/mucurses/slk.c
+++ b/src/hci/mucurses/slk.c
@@ -83,7 +83,7 @@ static void _print_label ( struct _softlabel sl ) {
space_ch = ' ';
// protect against gaps in the soft label keys array
- if ( sl.label == NULL ) {
+ if ( ! sl.label[0] ) {
memset( str, space_ch, (size_t)(slks->max_label_len) );
} else {
/* we need to pad the label with varying amounts of leading