func (c *Connection) SendCommand(commandName string, body []byte) error {
	cmdLen := len(commandName)
	if cmdLen > 255 {
		return errors.New("Command names may not be longer than 255 characters")
	}

	bodyLen := len(body)

	buf := make([]byte, 1+cmdLen+bodyLen) // FIXME(sbinet): maybe use a pool of []byte ?
	buf[0] = byte(cmdLen)
	copy(buf[1:], []byte(commandName))
	copy(buf[1+cmdLen:], body)

	return c.send(true, buf)
}
// SendCommand sends a ZMTP command over a Connection
SendCommand sends a ZMTP command over a Connection
// SendCommand sends a ZMTP command over a Connection
func (c *Connection) SendCommand(commandName string, body []byte) error {
	cmdLen := len(commandName)
	if cmdLen > 255 {
		return errors.New("Command names may not be longer than 255 characters")
	}
	bodyLen := len(body)
	buf := make([]byte, 1+cmdLen+bodyLen) 
	buf[0] = byte(cmdLen)
	copy(buf[1:], []byte(commandName))
	copy(buf[1+cmdLen:], body)
	return c.send(true, buf)
}
func ( c * Connection ) SendCommand ( commandName string , body [ ] byte ) error { cmdLen := len ( commandName ) if cmdLen > 255 { return errors . New ( " " ) } bodyLen := len ( body ) buf := make ( [ ] byte , 1 + cmdLen + bodyLen ) buf [ 0 ] = byte ( cmdLen ) copy ( buf [ 1 : ] , [ ] byte ( commandName ) ) copy ( buf [ 1 + cmdLen : ] , body ) return c . send ( true , buf ) }
SendCommand sends a ZMTP command over a Connection
SendCommand sends a ZMTP command over a Connection
// FIXME(sbinet): maybe use a pool of []byte ?