]> git.hungrycats.org Git - linux/commitdiff
net/unix/af_unix.c: Set msg_namelen in unix_copy_addr properly, define MODULE_LICENSE.
authorDavid S. Miller <davem@nuts.ninka.net>
Fri, 23 Aug 2002 12:03:09 +0000 (05:03 -0700)
committerDavid S. Miller <davem@nuts.ninka.net>
Fri, 23 Aug 2002 12:03:09 +0000 (05:03 -0700)
net/unix/af_unix.c

index e446be1eefc9efae96f3718a85b75384f577a274..e7bd766e6f399c0271f3752c8fd0d7f2b46a2bc5 100644 (file)
@@ -1408,7 +1408,7 @@ static void unix_copy_addr(struct msghdr *msg, struct sock *sk)
 {
        struct unix_sock *u = unix_sk(sk);
 
-       msg->msg_namelen = sizeof(short);
+       msg->msg_namelen = 0;
        if (u->addr) {
                msg->msg_namelen = u->addr->len;
                memcpy(msg->msg_name, u->addr->name, u->addr->len);
@@ -1917,8 +1917,4 @@ static void __exit af_unix_exit(void)
 module_init(af_unix_init);
 module_exit(af_unix_exit);
 
-/*
- * Local variables:
- *  compile-command: "gcc -g -D__KERNEL__ -Wall -O6 -I/usr/src/linux/include -c af_unix.c"
- * End:
- */
+MODULE_LICENSE("GPL");