diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2010-07-09 20:10:37 (GMT) |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2010-07-09 20:10:37 (GMT) |
commit | 29241eed563cf66439adf6fe6d1e0b5a0e700392 (patch) | |
tree | f5e5eac0345f6c0760b75ce1ae3d2d99a8889c23 | |
parent | 6f826469bb7fa9cde6a9658fd1f9b5115935137d (diff) | |
download | cpython-29241eed563cf66439adf6fe6d1e0b5a0e700392.zip cpython-29241eed563cf66439adf6fe6d1e0b5a0e700392.tar.gz cpython-29241eed563cf66439adf6fe6d1e0b5a0e700392.tar.bz2 |
Another temporary checkin to diagnose test_float failure on 3.1 Ubuntu buildbot.
-rw-r--r-- | Python/pystrtod.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/Python/pystrtod.c b/Python/pystrtod.c index 5fa51eb..0dea0a6 100644 --- a/Python/pystrtod.c +++ b/Python/pystrtod.c @@ -1001,9 +1001,17 @@ format_float_short(double d, char format_code, else { /* shouldn't get here: Gay's code should always return something starting with a digit, an 'I', or 'N' */ - strncpy(p, "ERR", 3); - p += 3; - /* assert(0); */ + printf("Unexpected failure in format_float_short. " + "Arguments: d = %.17g, format_code = %d, " + "mode = %d, precision = %ld\n", + d, format_code, mode, precision); + printf("digits == %.100s\n", digits); + PyErr_Format(PyExc_RuntimeError, + "Unexpected failure in format_float_short. " + "Arguments: d = %.17g, format_code = %d, " + "mode = %d, precision = %ld\n", + d, format_code, mode, precision); + return NULL; } goto exit; } |