gpg: Fix out-of-bound read in subpacket enumeration