]> git.decadent.org.uk Git - nfs-utils.git/commitdiff
Have sizeof using the correct value in nfs_getlocalport()
authorBen Greear <greearb@candelatech.com>
Wed, 4 Mar 2009 22:07:55 +0000 (17:07 -0500)
committerSteve Dickson <steved@redhat.com>
Wed, 4 Mar 2009 22:07:55 +0000 (17:07 -0500)
Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
support/nfs/getport.c

index bea3c98509137e81f58c9fa46b3dd1c96b965442..023c79a4b0153e2e1a3fbd71caad110760a1e8de 100644 (file)
@@ -833,7 +833,7 @@ unsigned short nfs_getlocalport(const rpcprot_t program,
 {
        struct sockaddr_storage address;
        struct sockaddr *lb_addr = (struct sockaddr *)&address;
-       socklen_t lb_len = sizeof(lb_addr);
+       socklen_t lb_len = sizeof(*lb_addr);
        unsigned short port = 0;
 
 #ifdef NFS_GP_LOCAL