sort out yet more type issues
authorEric Andersen <andersen@codepoet.org>
Mon, 30 Jan 2006 18:00:02 +0000 (18:00 -0000)
committerEric Andersen <andersen@codepoet.org>
Mon, 30 Jan 2006 18:00:02 +0000 (18:00 -0000)
archival/libunarchive/get_header_cpio.c
networking/libiproute/ipaddress.c
networking/libiproute/iplink.c
networking/libiproute/iproute.c
networking/libiproute/libnetlink.c
networking/libiproute/utils.c

index 11925c4e3e2b648aeab22734af6c1f50ced79328..bdd80dfea3173040d46c617cf632064d7de24810 100644 (file)
@@ -66,7 +66,7 @@ extern char get_header_cpio(archive_handle_t *archive_handle)
        /* There can be padding before archive header */
        data_align(archive_handle, 4);
 
-       if (archive_xread_all_eof(archive_handle, cpio_header, 110) == 0) {
+       if (archive_xread_all_eof(archive_handle, (unsigned char*)cpio_header, 110) == 0) {
                return(EXIT_FAILURE);
        }
        archive_handle->offset += 110;
index 12b8fc8f8cdef44386c41f6e080c8fa762555182..9db79eacb83be5c484a1ef49ad103112c3eb0821 100644 (file)
@@ -453,7 +453,7 @@ extern int ipaddr_list_or_flush(int argc, char **argv, int flush)
                                break;
                        case 1: /* scope */
                        {
-                               int scope = 0;
+                               uint32_t scope = 0;
                                NEXT_ARG();
                                filter.scopemask = -1;
                                if (rtnl_rtscope_a2n(&scope, *argv)) {
@@ -713,7 +713,7 @@ static int ipaddr_modify(int cmd, int argc, char **argv)
                        }
                        case 5: /* scope */
                        {
-                               int scope = 0;
+                               uint32_t scope = 0;
                                NEXT_ARG();
                                if (rtnl_rtscope_a2n(&scope, *argv)) {
                                        invarg(*argv, "invalid scope value.");
index 91c85820ca5c75801de1572a4208dd6ae0f8fa3f..12677d52263025dd4fb4226412ec4f7498e4a9fe 100644 (file)
@@ -166,7 +166,7 @@ static int get_address(char *dev, int *htype)
 {
        struct ifreq ifr;
        struct sockaddr_ll me;
-       int alen;
+       socklen_t alen;
        int s;
 
        s = socket(PF_PACKET, SOCK_DGRAM, 0);
@@ -211,7 +211,7 @@ static int parse_address(char *dev, int hatype, int halen, char *lla, struct ifr
        memset(ifr, 0, sizeof(*ifr));
        strcpy(ifr->ifr_name, dev);
        ifr->ifr_hwaddr.sa_family = hatype;
-       alen = ll_addr_a2n(ifr->ifr_hwaddr.sa_data, 14, lla);
+       alen = ll_addr_a2n((unsigned char *)(ifr->ifr_hwaddr.sa_data), 14, lla);
        if (alen < 0)
                return -1;
        if (alen != halen) {
index 1c4f75520fd68195a4159751629cc0369550c411..7b513005013e8e1337b16f788216561baf5cd72a 100644 (file)
@@ -347,7 +347,7 @@ static int iproute_modify(int cmd, unsigned flags, int argc, char **argv)
                        }
                        rta_addattr32(mxrta, sizeof(mxbuf), RTAX_MTU, mtu);
                } else if (matches(*argv, "protocol") == 0) {
-                       int prot;
+                       uint32_t prot;
                        NEXT_ARG();
                        if (rtnl_rtprot_a2n(&prot, *argv))
                                invarg("\"protocol\" value is invalid\n", *argv);
@@ -493,7 +493,7 @@ static int iproute_list_or_flush(int argc, char **argv, int flush)
 
        while (argc > 0) {
                if (matches(*argv, "protocol") == 0) {
-                       int prot = 0;
+                       uint32_t prot = 0;
                        NEXT_ARG();
                        filter.protocolmask = -1;
                        if (rtnl_rtprot_a2n(&prot, *argv)) {
index 5545be8fe4728e5d904af10a195ccad8bd455bf9..efbb6f104d1df4247aec3091e29af0798c0236ff 100644 (file)
@@ -30,7 +30,7 @@ void rtnl_close(struct rtnl_handle *rth)
 
 int rtnl_open(struct rtnl_handle *rth, unsigned subscriptions)
 {
-       int addr_len;
+       socklen_t addr_len;
 
        memset(rth, 0, sizeof(rth));
 
index 0dd5d951906a6f8c1c2a76e3c88b07b8501adb9e..984f7bed9e6f808e03df051354b987081ec7316b 100644 (file)
@@ -164,7 +164,7 @@ int get_addr_1(inet_prefix * addr, char *name, int family)
 int get_prefix_1(inet_prefix * dst, char *arg, int family)
 {
        int err;
-       unsigned plen;
+       int plen;
        char *slash;
 
        memset(dst, 0, sizeof(*dst));