Print signed single-byte decimal integers correctly instead of implicitly
converting them to unsigned bytes. PR: 36783
This commit is contained in:
parent
04cbf1cb05
commit
3e9f4fc172
@ -154,7 +154,7 @@ print(pr, bp)
|
|||||||
case F_INT:
|
case F_INT:
|
||||||
switch(pr->bcnt) {
|
switch(pr->bcnt) {
|
||||||
case 1:
|
case 1:
|
||||||
(void)printf(pr->fmt, (quad_t)*bp);
|
(void)printf(pr->fmt, (quad_t)(signed char)*bp);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
bcopy(bp, &s2, sizeof(s2));
|
bcopy(bp, &s2, sizeof(s2));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user