Commit f15abac
nbd: Remove redundant sock->ops->shutdown() check in nbd_get_socket().
Since commit 9f7c02e ("nbd: restrict sockets to TCP
and UDP") (s/UDP/AF_UNIX/), NBD only accepts TCP and AF_UNIX
SOCK_STREAM sockets as backend.
nbd_get_socket() currently checks if sock->ops->shutdown()
is sock_no_shutdown(), but sock->ops->shutdown() is always
inet_shutdown() or unix_shutdown() for these socket types.
Let's remove the redundant check.
Signed-off-by: Kuniyuki Iwashima <[email protected]>1 parent 359a150 commit f15abac
1 file changed
Lines changed: 0 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1228 | 1228 | | |
1229 | 1229 | | |
1230 | 1230 | | |
1231 | | - | |
1232 | | - | |
1233 | | - | |
1234 | | - | |
1235 | | - | |
1236 | | - | |
1237 | | - | |
1238 | 1231 | | |
1239 | 1232 | | |
1240 | 1233 | | |
| |||
0 commit comments