summaryrefslogtreecommitdiff
path: root/source4/build/pidl
diff options
context:
space:
mode:
Diffstat (limited to 'source4/build/pidl')
-rw-r--r--source4/build/pidl/proxy.pm11
1 files changed, 9 insertions, 2 deletions
diff --git a/source4/build/pidl/proxy.pm b/source4/build/pidl/proxy.pm
index a09a8be5d4..1eef131a6c 100644
--- a/source4/build/pidl/proxy.pm
+++ b/source4/build/pidl/proxy.pm
@@ -139,7 +139,14 @@ static NTSTATUS dcom_proxy_$interface->{NAME}_$name(struct dcom_interface_p *d,
$res .="
NTSTATUS dcom_$interface->{NAME}_$name (struct dcom_interface_p *d, TALLOC_CTX *mem_ctx, struct $name *r)
{
- return ((const struct dcom_$interface->{NAME}_vtable *)d->vtable)->$name (d, mem_ctx, r);
+ const struct dcom_$interface->{NAME}_vtable *table = d->vtable;
+
+ if (table->$name == NULL) {
+ DEBUG(0, (\"Object does not implement $name of interface $interface->{NAME}\\n\"));
+ return NT_STATUS_NOT_IMPLEMENTED;
+ }
+
+ return table->$name (d, mem_ctx, r);
}
";
}
@@ -151,7 +158,7 @@ sub ParseInterface($)
{
my($interface) = shift;
my($data) = $interface->{DATA};
- $res = "/* DCOM stubs generated by pidl */\n\n";
+ $res = "/* DCOM proxy generated by pidl */\n\n";
foreach my $d (@{$data}) {
($d->{TYPE} eq "FUNCTION") &&
ParseFunction($interface, $d);