gpg: Fix a NULL-deref in export due to invalid packet lengths.
* g10/build-packet.c (write_fake_data): Take care of a NULL stored as opaque MPI.
(back ported from commit 0835d2f44ef62eab51fce6a927908f544e01cf8f)
[dkg: rebased to STABLE-BRANCH-1-4]
- Reported-by: Hanno Böck <hanno@hboeck.de>
- Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>