Skip to content

Commit

Permalink
net: socket: drop unneeded likely() call around IS_ERR()
Browse files Browse the repository at this point in the history
IS_ERR() already calls unlikely(), so this extra likely() call
around the !IS_ERR() is not needed.

Signed-off-by: Enrico Weigelt <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
metux authored and davem330 committed Jun 5, 2019
1 parent 856e6d9 commit 4546e44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ static int sock_map_fd(struct socket *sock, int flags)
}

newfile = sock_alloc_file(sock, flags, NULL);
if (likely(!IS_ERR(newfile))) {
if (!IS_ERR(newfile)) {
fd_install(fd, newfile);
return fd;
}
Expand Down

0 comments on commit 4546e44

Please sign in to comment.