On 25/02/17 16:28, Илья Шипицин wrote:
>
> but for "[src/openvpn/error.c:824]: (error) Null pointer dereference",
> I'm afraid we should guard it with "#if 0", otherwise static analyzer
> will continue complain

No.  That function in error.c:824, crash(), which is only enabled with
ENABLE_DEBUG is explicitly written that way to crash OpenVPN when
called.  So that is purely a false positive, as the static analyzer
doesn't expect such nasty code to be there with a purpose.  But
triggering a crash like that can have some use case in some special
situations.

Normal builds should generally not be built with ENABLE_DEBUG, that is a
intended as a "developer mode".

We should generally avoid '#if 0' or even '#if 1' as much as possible in
the code.


-- 
kind regards,

David Sommerseth
OpenVPN Technologies, Inc


Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to