Skip to content

Commit a0e1c71

Browse files
committed
Include arpa/inet.h instead of sys/endian.h
The header is included to get defintion for htons. In termux the definition is in sys/endian.h, but on other systems it is in arpa/inet.h. arpa/inet.h includes sys/endian.h though, so including that header works in termux as well. Change to arpa/inet.h so that termux-api-package can be easily compiled both in termux and for other systems.
1 parent 22d6c10 commit a0e1c71

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

termux-api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include <stdio.h>
99
#include <stdlib.h>
1010
#include <string.h>
11-
#include <sys/endian.h>
11+
#include <arpa/inet.h>
1212
#include <sys/socket.h>
1313
#include <sys/stat.h>
1414
#include <sys/types.h>

0 commit comments

Comments
 (0)