We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4e6bf49 commit 0e7a0edCopy full SHA for 0e7a0ed
1 file changed
Python/pystrtod.c
@@ -41,7 +41,7 @@ double
41
PyOS_ascii_strtod(const char *nptr, char **endptr)
42
{
43
char *fail_pos;
44
- double val;
+ double val = -1.0;
45
struct lconv *locale_data;
46
const char *decimal_point;
47
int decimal_point_len;
@@ -130,7 +130,7 @@ PyOS_ascii_strtod(const char *nptr, char **endptr)
130
if (nptr[i] == '-')
131
i++;
132
if (nptr[i] == '0' && (nptr[i+1] == 'x' || nptr[i+1] == 'X'))
133
- fail_pos = nptr;
+ fail_pos = (char*)nptr;
134
else
135
val = strtod(nptr, &fail_pos);
136
}
0 commit comments