(Fformat): Don't sign-extend for %o or %x.
This commit is contained in:
parent
fd2adae323
commit
de92d4d43e
1 changed files with 7 additions and 1 deletions
|
@ -3758,7 +3758,13 @@ usage: (format STRING &rest OBJECTS) */)
|
|||
this_format[format - this_format_start] = 0;
|
||||
|
||||
if (INTEGERP (args[n]))
|
||||
sprintf (p, this_format, XINT (args[n]));
|
||||
{
|
||||
if (format[-1] == 'd')
|
||||
sprintf (p, this_format, XINT (args[n]));
|
||||
/* Don't sign-extend for octal or hex printing. */
|
||||
else
|
||||
sprintf (p, this_format, XUINT (args[n]));
|
||||
}
|
||||
else
|
||||
sprintf (p, this_format, XFLOAT_DATA (args[n]));
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue