Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Olivier B.
pybind11
Commits
95d18691
Commit
95d18691
authored
Jan 17, 2016
by
Wenzel Jakob
Browse files
minor fixes & removed a leak when freeing functions
parent
b2c2c792
Changes
1
Hide whitespace changes
Inline
Side-by-side
include/pybind11/pybind11.h
View file @
95d18691
...
...
@@ -341,7 +341,6 @@ private:
static
void
destruct
(
function_entry
*
entry
)
{
while
(
entry
)
{
function_entry
*
next
=
entry
->
next
;
delete
entry
->
def
;
if
(
entry
->
free_data
)
entry
->
free_data
(
entry
->
data
);
std
::
free
((
char
*
)
entry
->
name
);
...
...
@@ -352,6 +351,10 @@ private:
std
::
free
((
char
*
)
arg
.
descr
);
Py_XDECREF
(
arg
.
value
);
}
if
(
entry
->
def
)
{
free
((
char
*
)
entry
->
def
->
ml_doc
);
delete
entry
->
def
;
}
delete
entry
;
entry
=
next
;
}
...
...
@@ -410,7 +413,7 @@ private:
signature
+=
c
;
}
}
if
(
type_depth
!=
0
&&
types
[
type_index
]
!=
nullptr
)
if
(
type_depth
!=
0
||
types
[
type_index
]
!=
nullptr
)
throw
std
::
runtime_error
(
"Internal error while parsing type signature (2)"
);
#if !defined(PYBIND11_CPP14)
...
...
Write
Preview
Supports
Markdown
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