qtest: fix hex2nib for capital characters
Signed-off-by: Sergey Fedorov <serge.fdrv@gmail.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
parent
ef18c2f54e
commit
2a802aaf63
2
qtest.c
2
qtest.c
@ -148,7 +148,7 @@ static int hex2nib(char ch)
|
|||||||
} else if (ch >= 'a' && ch <= 'f') {
|
} else if (ch >= 'a' && ch <= 'f') {
|
||||||
return 10 + (ch - 'a');
|
return 10 + (ch - 'a');
|
||||||
} else if (ch >= 'A' && ch <= 'F') {
|
} else if (ch >= 'A' && ch <= 'F') {
|
||||||
return 10 + (ch - 'a');
|
return 10 + (ch - 'A');
|
||||||
} else {
|
} else {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user