From 334203f7c588eca1426251fc3cdcf74a1ba408c6 Mon Sep 17 00:00:00 2001 From: Medour Mehdi Date: Tue, 3 Sep 2024 23:00:20 +0200 Subject: [PATCH] Code formatting & Typo error fixed --- socket/if_freenameindex.c | 3 ++- socket/if_indextoname.c | 2 +- socket/if_nameindex.c | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/socket/if_freenameindex.c b/socket/if_freenameindex.c index 7f79ac9..0cb91a1 100644 --- a/socket/if_freenameindex.c +++ b/socket/if_freenameindex.c @@ -3,7 +3,8 @@ __typeof__(if_freenameindex) __if_freenameindex; -void __if_freenameindex(struct if_nameindex *idx) +void +__if_freenameindex(struct if_nameindex *idx) { free(idx); } diff --git a/socket/if_indextoname.c b/socket/if_indextoname.c index 5d74ee4..90e7420 100644 --- a/socket/if_indextoname.c +++ b/socket/if_indextoname.c @@ -7,7 +7,7 @@ __typeof__(if_indextoname) __if_indextoname; -char * +char* __if_indextoname(unsigned short index, char name[IF_NAMESIZE]) { struct ifreq ifr; diff --git a/socket/if_nameindex.c b/socket/if_nameindex.c index 35bbc5d..e11d8ea 100644 --- a/socket/if_nameindex.c +++ b/socket/if_nameindex.c @@ -77,7 +77,8 @@ __typeof__(if_nameindex) __if_nameindex; -struct if_nameindex *__if_nameindex (void) +struct if_nameindex* +__if_nameindex (void) { struct ifaddrs *ifaddrs, *ifa; unsigned int ni;