Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Boxiang Sun
/
cython
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit 775fb036
authored
2018-10-03 12:40:09 +0200
by
Robert Bradshaw
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Allocate sufficient space for null termination.
1 parent
d1cf2648
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
Cython/Utility/TypeConversion.c
Cython/Utility/TypeConversion.c
View file @
775fb03
...
...
@@ -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
);
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment