*p++ = xdig[*v++];
/* The radix is always output after the first
- * non-zero xdigit, or if alt. */
- if (vfnz < vlnz || alt) {
+ * non-zero xdigit, or if precis, or if alt. */
+ if (vfnz < vlnz || precis > 0 || alt) {
#ifndef USE_LOCALE_NUMERIC
*p++ = '.';
#else
[ '% 20.10a', '3.14', ' 0x1.91eb851eb8p+1' ],
[ '%020.10a', '3.14', '0x0001.91eb851eb8p+1' ],
+ [ '%.13a', '1', '0x1.0000000000000p+0' ],
+ [ '%.13a', '-1', '-0x1.0000000000000p+0' ],
+
[ '%30a', '3.14', ' 0x1.91eb851eb851fp+1' ],
[ '%-30a', '3.14', '0x1.91eb851eb851fp+1 ' ],
[ '%030a', '3.14', '0x00000000001.91eb851eb851fp+1' ],