apps: when the 'compat' nameopt has been set, leave it be
authorRichard Levitte <levitte@openssl.org>
Thu, 31 May 2018 04:51:25 +0000 (06:51 +0200)
committerRichard Levitte <levitte@openssl.org>
Thu, 31 May 2018 09:01:57 +0000 (11:01 +0200)
commit7e2e10aaec5461915a074aff42285916bd7da3cf
treec39a328af87ca97c0da10b7ee8d7a09c6ee407a1
parent6912debb881e669f7a7fb621588e20347111c4f0
apps: when the 'compat' nameopt has been set, leave it be

XN_FLAG_COMPAT has a unique property, its zero for value.  This means
it needs special treatment; if it has been set (which can only be
determined indirectly) and set alone (*), no other flags should be
set.

(*) if any other nameopt flag has been set by the user, compatibility
mode is blown away.

Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/6382)

(cherry picked from commit 3190d1dca43ecfd748c06aa06752de06af3768b9)
apps/apps.c