Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
nexedi
cython
Commits
775fb036
Commit
775fb036
authored
6 years ago
by
Robert Bradshaw
Browse files
Options
Download
Email Patches
Plain Diff
Allocate sufficient space for null termination.
parent
d1cf2648
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
Cython/Utility/TypeConversion.c
Cython/Utility/TypeConversion.c
+1
-1
No files found.
Cython/Utility/TypeConversion.c
View file @
775fb036
...
...
@@ -178,7 +178,7 @@ static int __Pyx_init_sys_getdefaultencoding_params(void) {
if
(
!
default_encoding
)
goto
bad
;
default_encoding_c
=
PyBytes_AsString
(
default_encoding
);
if
(
!
default_encoding_c
)
goto
bad
;
__PYX_DEFAULT_STRING_ENCODING
=
(
char
*
)
malloc
(
strlen
(
default_encoding_c
));
__PYX_DEFAULT_STRING_ENCODING
=
(
char
*
)
malloc
(
strlen
(
default_encoding_c
)
+
1
);
if
(
!
__PYX_DEFAULT_STRING_ENCODING
)
goto
bad
;
strcpy
(
__PYX_DEFAULT_STRING_ENCODING
,
default_encoding_c
);
Py_DECREF
(
default_encoding
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment