created struct and list; msglen is working