]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/core/scm.c
Merge tag 'firewire-fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394...
[karo-tx-linux.git] / net / core / scm.c
index 9c1c63da3ca8a99ce8ac25e8f1abf9e309075740..ab570841a532ea318b5133596f1957192ff01354 100644 (file)
@@ -301,11 +301,10 @@ void scm_detach_fds(struct msghdr *msg, struct scm_cookie *scm)
                        break;
                }
                /* Bump the usage count and install the file. */
-               get_file(fp[i]);
                sock = sock_from_file(fp[i], &err);
                if (sock)
                        sock_update_netprioidx(sock->sk, current);
-               fd_install(new_fd, fp[i]);
+               fd_install(new_fd, get_file(fp[i]));
        }
 
        if (i > 0)