Commit 911231e7 authored by Victor Stinner's avatar Victor Stinner Committed by GitHub

Drop confusing commented out code in pystrtod.c (GH-6072) (GH-9588)

Fix the following warning:

Python/pystrtod.c: In function 'format_float_short':
Python/pystrtod.c:1007:13: warning: 'strncpy' output truncated before terminating nul copying 3 bytes from a string of the same length [-Wstringop-truncation]
             strncpy(p, "ERR", 3);

(cherry picked from commit 9fb84157)
parent 65fa1264
......@@ -1004,8 +1004,6 @@ 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);
}
goto exit;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment