public void PutAttribute(ControlAttribute attribute)
{
if (ControlHeader.CONTROL_HEADER_BYTES + header.payload_length + attribute.GetTotalLength() > CONTROL_MAX_PAYLOAD_LENGTH)
throw new ArgumentException ("Putting attribute would exceed maximum message length");
attributes.Add (attribute);
header.payload_length += attribute.GetTotalLength ();
}