Only set `msg_len` once