getprotobyname() returns p_proto in host endian, so it should not be converted with ntoh. (Note: getservbyname() on the other hand does return s_port in network endian) Signed-off-by: Petrus Hellgren <petrus.hellgren@westermo.se>