Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
423abd9d
Commit
423abd9d
authored
Feb 26, 2005
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://kernel.bkbits.net/davem/net-2.6
into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents
a77e4c96
56b5adfb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
5 deletions
+12
-5
net/ipv4/fib_hash.c
net/ipv4/fib_hash.c
+2
-2
net/unix/af_unix.c
net/unix/af_unix.c
+10
-3
No files found.
net/ipv4/fib_hash.c
View file @
423abd9d
...
...
@@ -684,7 +684,7 @@ fn_hash_dump_bucket(struct sk_buff *skb, struct netlink_callback *cb,
list_for_each_entry
(
fa
,
&
f
->
fn_alias
,
fa_list
)
{
if
(
i
<
s_i
)
continue
;
goto
next
;
if
(
fib_dump_info
(
skb
,
NETLINK_CB
(
cb
->
skb
).
pid
,
cb
->
nlh
->
nlmsg_seq
,
...
...
@@ -699,7 +699,7 @@ fn_hash_dump_bucket(struct sk_buff *skb, struct netlink_callback *cb,
cb
->
args
[
3
]
=
i
;
return
-
1
;
}
next:
i
++
;
}
}
...
...
net/unix/af_unix.c
View file @
423abd9d
...
...
@@ -1850,15 +1850,22 @@ static int unix_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
case
SIOCINQ
:
{
struct
sk_buff
*
skb
;
if
(
sk
->
sk_state
==
TCP_LISTEN
)
{
err
=
-
EINVAL
;
break
;
}
spin_lock
(
&
sk
->
sk_receive_queue
.
lock
);
skb
=
skb_peek
(
&
sk
->
sk_receive_queue
);
if
(
skb
)
amount
=
skb
->
len
;
if
(
sk
->
sk_type
==
SOCK_STREAM
||
sk
->
sk_type
==
SOCK_SEQPACKET
)
{
skb_queue_walk
(
&
sk
->
sk_receive_queue
,
skb
)
amount
+=
skb
->
len
;
}
else
{
skb
=
skb_peek
(
&
sk
->
sk_receive_queue
);
if
(
skb
)
amount
=
skb
->
len
;
}
spin_unlock
(
&
sk
->
sk_receive_queue
.
lock
);
err
=
put_user
(
amount
,
(
int
__user
*
)
arg
);
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment