aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2020-08-31 15:56:53 (GMT)
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2020-09-21 00:26:37 (GMT)
commitd32e569d045fa2d7f360b3df955da5bded2e7ef1 (patch)
tree50d87f6bd4e8f94c40bac8fa2596604fef39e65c
parent41808e5d12b1a39f687468b6b81c75c7a4fc0203 (diff)
downloadhardware_replicant_libsamsung-ipc-d32e569d045fa2d7f360b3df955da5bded2e7ef1.zip
hardware_replicant_libsamsung-ipc-d32e569d045fa2d7f360b3df955da5bded2e7ef1.tar.gz
hardware_replicant_libsamsung-ipc-d32e569d045fa2d7f360b3df955da5bded2e7ef1.tar.bz2
samsung-ipc/utils: reorder includes
This reorders includes alphabetically and groups them together: - C standard library includes of depth 1 are grouped together - "System" libraries of depth > 1 age grouped together - The (lib)samsung-ipc include(s) is/are grouped together We also need to keep the inclusion of sys/socket.h before linux/netlink.h in order to prevent the following compilation error on Replicant 4.2: bionic/libc/kernel/common/linux/netlink.h:52:2: error: unknown type name 'sa_family_t' While Replicant 4.2 is not really maintained anymore, it is still being used for testing libsamsung-ipc on devices that are not supported anymore by more recent Replicant versions, so we need to keep libsamsung-ipc and libsamsung-ril working on it. Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
-rw-r--r--samsung-ipc/utils.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/samsung-ipc/utils.c b/samsung-ipc/utils.c
index da35e59..85f06cf 100644
--- a/samsung-ipc/utils.c
+++ b/samsung-ipc/utils.c
@@ -17,20 +17,23 @@
* along with libsamsung-ipc. If not, see <http://www.gnu.org/licenses/>.
*/
+#include <ctype.h>
+#include <fcntl.h>
+#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
-#include <stdint.h>
-#include <unistd.h>
#include <string.h>
-#include <fcntl.h>
-#include <ctype.h>
+#include <unistd.h>
+
+#include <asm/types.h>
+#include <net/if.h>
#include <sys/ioctl.h>
+#include <sys/socket.h>
#include <sys/stat.h>
#include <sys/types.h>
-#include <sys/socket.h>
-#include <asm/types.h>
+
+/* linux/netlink.h needs to be included after sys/socket.h */
#include <linux/netlink.h>
-#include <net/if.h>
#include <samsung-ipc.h>