mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
pidl:python: Exception if unconvertable in ConvertObjectToPythonLevel
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
f893c100c0
commit
ea78a5ce83
@ -2295,6 +2295,10 @@ sub ConvertObjectToPythonLevel($$$$$$$)
|
||||
}
|
||||
my $conv = $self->ConvertObjectToPythonData($mem_ctx, $l->{DATA_TYPE}, $var_name, $e->{ORIGINAL});
|
||||
$self->pidl("$py_var = $conv;");
|
||||
if ($conv eq "NULL") {
|
||||
$self->pidl("PyErr_SetString(PyExc_NotImplementedError, \"Cannot convert NDR $var_name to Python\");");
|
||||
$self->pidl("$fail");
|
||||
}
|
||||
} elsif ($l->{TYPE} eq "SUBCONTEXT") {
|
||||
$self->ConvertObjectToPythonLevel($mem_ctx, $env, $e, $nl, $var_name, $py_var, $fail, $recurse);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user