Coverity errors in libndr/

tridge at tridge at
Wed Oct 25 11:56:00 GMT 2006


 > I was not talking about ldb, I was talking about generated
 > NDR marshalling code. In ndr_echo.c starting with line 1162
 > we have the following code fragment:

oh, sorry!

 >       ndr_print_echo_Enum1(ndr, "foo1", *r->in.foo1);
 >       ndr->depth--;
 >       ndr_print_ptr(ndr, "foo2", r->in.foo2);
 >       ndr->depth++;
 >       ndr_print_echo_Enum2(ndr, "foo2", r->in.foo2);
 >       ndr->depth--;
 >       ndr_print_ptr(ndr, "foo3", r->in.foo3);
 >       ndr->depth++;
 >       if (r->in.foo1 == NULL) return;
 > I think the last line is bogus, as in the first line we
 > already segfaulted. Or should I mark these as wontfix in
 > coverity?

yes, last line is bogus. It should be fixable in pidl. I'll leave it
to Jelmer to see just how painful the fix is (I don't think it will be
bad - just need to check for a ref ptr and avoid generating that NULL

Is it ok to leave this in coverity until Jelmer has a chance to have a
look at a fix?

Cheers, Tridge

More information about the samba-technical mailing list