channels/rdpgfx: harden parsing code