delorie.com/djgpp/doc/libc/libc_599.html | search |
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
#include <netinet/in.h> unsigned short ntohs(unsigned short val); |
This function converts from network formatted shorts to host formatted shorts. For the i386 and higher processors, this means that the bytes are swapped from 12 order to 21 order.
The host-order value.
ANSI/ISO C | No |
POSIX | No |
port = ntohs(tcp.port); |
webmaster | delorie software privacy |
Copyright © 2004 | Updated Apr 2004 |