[PATCH 4/9] ap: Fix an invalid access in ap_write_wsc_ie