diff options
author | Werner Koch <[email protected]> | 2014-09-18 13:08:51 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2015-10-01 05:32:50 +0000 |
commit | b1653a4083b91cfa85d90f59612fa1c3f4d51778 (patch) | |
tree | 79466994d211a3f1ee222bda687e20d7266bf3b3 | |
parent | gpg: Improve 'General key info' line of --card-status. (diff) | |
download | gnupg-b1653a4083b91cfa85d90f59612fa1c3f4d51778.tar.gz gnupg-b1653a4083b91cfa85d90f59612fa1c3f4d51778.zip |
gpg: Silence a compiler warning.
* g10/parse-packet.c (enum_sig_subpkt): Replace hack.
--
GCC 5 failure reported by Kevin Locke <[email protected]>
(backport from master commit 6a0c3fa19cfcdd590b96691e8a8ffb48fb5e0ec4)
-rw-r--r-- | g10/parse-packet.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/g10/parse-packet.c b/g10/parse-packet.c index a8f9d99f4..c925e9440 100644 --- a/g10/parse-packet.c +++ b/g10/parse-packet.c @@ -1258,10 +1258,10 @@ enum_sig_subpkt( const subpktarea_t *pktbuf, sigsubpkttype_t reqtype, critical=&critical_dummy; if( !pktbuf || reqseq == -1 ) { - /* return some value different from NULL to indicate that - * there is no critical bit we do not understand. The caller - * will never use the value. Yes I know, it is an ugly hack */ - return reqtype == SIGSUBPKT_TEST_CRITICAL? (const byte*)&pktbuf : NULL; + static char dummy[] = "x"; + /* Return a value different from NULL to indicate that + * there is no critical bit we do not understand. */ + return reqtype == SIGSUBPKT_TEST_CRITICAL ? dummy : NULL; } buffer = pktbuf->data; buflen = pktbuf->len; |