JM プロジェクトは、主に Linux 関連のマニュアルページの日本語ページを翻訳・公開しています。
... stlong ); uint16_t htons(uint16_t hostshort ); uint32_t ntohl(uint32_t netlong ); uint16_t ntohs(uint16_t netshort ); 説明 htonl () 関数は unsigned integer hostlong を ホストバイトオーダーからネットワークバイトオーダーに変換する。 htons () 関数は unsi ... 位バイト が先に配置される。 属性 この節で使用されている用語の説明は attributes (7) を参照のこと。 Interface Attribute Value htonl (), htons (), ntohl (), ntohs () Thread safety MT-Safe 準拠 POSIX.1-2001, POSIX.1-2008. いくつかのシステムでは、 < arpa/in ... ... stlong ); uint16_t htons(uint16_t hostshort ); uint32_t ntohl(uint32_t netlong ); uint16_t ntohs(uint16_t netshort ); 説明 htonl () 関数は unsigned integer hostlong を ホストバイトオーダーからネットワークバイトオーダーに変換する。 htons () 関数は unsi ... 位バイト が先に配置される。 属性 この節で使用されている用語の説明は attributes (7) を参照のこと。 Interface Attribute Value htonl (), htons (), ntohl (), ntohs () Thread safety MT-Safe 準拠 POSIX.1-2001, POSIX.1-2008. いくつかのシステムでは、 < arpa/in ... ... stlong ); uint16_t htons(uint16_t hostshort ); uint32_t ntohl(uint32_t netlong ); uint16_t ntohs(uint16_t netshort ); 説明 htonl () 関数は unsigned integer hostlong を ホストバイトオーダーからネットワークバイトオーダーに変換する。 htons () 関数は unsi ... 位バイト が先に配置される。 属性 この節で使用されている用語の説明は attributes (7) を参照のこと。 Interface Attribute Value htonl (), htons (), ntohl (), ntohs () Thread safety MT-Safe 準拠 POSIX.1-2001, POSIX.1-2008. いくつかのシステムでは、 < arpa/in ... ... stlong ); uint16_t htons(uint16_t hostshort ); uint32_t ntohl(uint32_t netlong ); uint16_t ntohs(uint16_t netshort ); 説明 htonl () 関数は unsigned integer hostlong を ホストバイトオーダーからネットワークバイトオーダーに変換する。 htons () 関数は unsi ... 位バイト が先に配置される。 属性 この節で使用されている用語の説明は attributes (7) を参照のこと。 Interface Attribute Value htonl (), htons (), ntohl (), ntohs () Thread safety MT-Safe 準拠 POSIX.1-2001, POSIX.1-2008. いくつかのシステムでは、 < arpa/in ... ... stlong ); uint16_t htons(uint16_t hostshort ); uint32_t ntohl(uint32_t netlong ); uint16_t ntohs(uint16_t netshort ); 説明 htonl () 関数は unsigned integer hostlong を ホストバイトオーダーからネットワークバイトオーダーに変換する。 htons () 関数は unsi ... 位バイト が先に配置される。 属性 この節で使用されている用語の説明は attributes (7) を参照のこと。 Interface Attribute Value htonl (), htons (), ntohl (), ntohs () Thread safety MT-Safe 準拠 POSIX.1-2001, POSIX.1-2008. いくつかのシステムでは、 < arpa/in ... ... DGRAM, 0); if (sockfd == -1) { perror("socket()"); exit(EXIT_FAILURE); } addr.sin_family = AF_INET; addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); addr.sin_port = htons(1234); if (connect(sockfd, (struct sockaddr *) &addr, sizeof(addr)) == -1) { perro ... ... DGRAM, 0); if (sockfd == -1) { perror("socket()"); exit(EXIT_FAILURE); } addr.sin_family = AF_INET; addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); addr.sin_port = htons(1234); if (bind(sockfd, (struct sockaddr *) &addr, sizeof(addr)) == -1) { perror(" ... ... t_net_ntop() では変更されない場合があり、 その場合 argv[2] で指定された初期値のままになる。 */ printf("Raw address: %x\n", htonl(addr.s_addr)); exit(EXIT_SUCCESS); } 関連項目 inet (3), networks (5) この文書について この man ページは Linux man-pages プ ... ... t_net_ntop() では変更されない場合があり、 その場合 argv[2] で指定された初期値のままになる。 */ printf("Raw address: %x\n", htonl(addr.s_addr)); exit(EXIT_SUCCESS); } 関連項目 inet (3), networks (5) この文書について この man ページは Linux man-pages プ ... ... erface address in network byte order. in_addr should be assigned one of the INADDR_* values (e.g., INADDR_LOOPBACK ) using htonl (3) or set using the inet_aton (3), inet_addr (3), inet_makeaddr (3) library functions or directly with the name resolver ... IP レベルが使用されている。 INADDR_ANY (0.0.0.0) and INADDR_BROADCAST (255.255.255.255) are byte-order-neutral. This means htonl (3) has no effect on them. 移植性 Linux 2.0 との互換性のために、 obsolete な socket(AF_INET, SOCK_PACKET, protocol ) という ... 日本語の文書やマニュアルを配布している個人/プロジェクトへのリンクです。