diff --git a/proto/ei-proto.c.tmpl b/proto/ei-proto.c.tmpl index aab4735..4ede48a 100644 --- a/proto/ei-proto.c.tmpl +++ b/proto/ei-proto.c.tmpl @@ -73,6 +73,9 @@ const struct brei_object * int {{outgoing.fqdn}}({{interface.as_arg}}{%- for arg in outgoing.arguments %}, {{arg.as_arg}}{% endfor %}) { + if (!{{interface.name}}) + return -ENOENT; + const struct brei_object *obj = {{interface.name}}_get_proto_object({{interface.name}}); {{target.ctype}} ctx = {{interface.name}}_get_{{target.context}}({{interface.name}});