summaryrefslogtreecommitdiffstats
path: root/call/call.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2017-01-31 11:48:05 +0100
committerRalf Baechle <ralf@linux-mips.org>2017-01-31 11:48:05 +0100
commit216aa966d5fd1fcaf4e15eba025910b7282c29a6 (patch)
tree67d80f9dc6339a9ff1a682d5365c017f8044dbc5 /call/call.c
parentae7c84e27c72f85ce840db6261080d1187adeb4f (diff)
call: Fix error check on iconv's return value.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'call/call.c')
-rw-r--r--call/call.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/call/call.c b/call/call.c
index 022f6a3..790318e 100644
--- a/call/call.c
+++ b/call/call.c
@@ -189,7 +189,7 @@ static int widthchar(char *s, size_t bytes, int xpos)
/*
* Note: Actually need to check if bad UTF8 characters show as ?
*/
- if (iconv(utf8towchart, &s, &bytes, &outbuf, &outsize)< 0)
+ if (iconv(utf8towchart, &s, &bytes, &outbuf, &outsize) == (size_t) -1)
return 0;
if (c == 9) {
return 8 - (xpos & 7);