core: revert two of the changes in Bllacky's pull request.

`ndigits` is actually an int, used as a field width specifier in
snprintf().

s is an extensively-used pointer.