gpg: Assert that an opaque parameter is really what we expect.
authorWerner Koch <wk@gnupg.org>
Fri, 31 Mar 2017 18:06:54 +0000 (20:06 +0200)
committerWerner Koch <wk@gnupg.org>
Fri, 31 Mar 2017 18:07:33 +0000 (20:07 +0200)
commit52ba5e67cad4311d0ddbc4f2979e20afd0161d1f
tree0d959d3440502898ba87c75fc8ca97daab2cf49f
parent8f2671d2cc022af2f564e296bdeb3bb2d2734ef4
gpg: Assert that an opaque parameter is really what we expect.

* g10/gpg.h (SERVER_CONTROL_MAGIC): New const.
(server_control_s): Add field 'magic'.
* g10/gpg.c (gpg_init_default_ctrl): Init MAGIC.
* g10/import.c (impex_filter_getval): Assert MAGIC.

Signed-off-by: Werner Koch <wk@gnupg.org>
g10/gpg.c
g10/gpg.h
g10/import.c