diff mbox

[net-next-2.6] Phonet: remove dangling pipe if an endpoint is closed early

Message ID 20100915.213518.137835427.davem@davemloft.net
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

David Miller Sept. 16, 2010, 4:35 a.m. UTC
From: David Miller <davem@davemloft.net>

Date: Wed, 15 Sep 2010 21:32:58 -0700 (PDT)

> Applied.


Btw, I had to apply the following warning fix against your other
set of changes.

--------------------
phonet: Fix build warning.

net/phonet/socket.c: In function ‘pn_res_seq_show’:
net/phonet/socket.c:726: warning: format ‘%02X’ expects type ‘unsigned int’, but argument 3 has type ‘long int’

Signed-off-by: David S. Miller <davem@davemloft.net>

---
 net/phonet/socket.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

-- 
1.7.2.2

Comments

Rémi Denis-Courmont Sept. 16, 2010, 4:41 a.m. UTC | #1
Hello,

On Thursday 16 September 2010, David Miller wrote:
> From: David Miller <davem@davemloft.net>
> Date: Wed, 15 Sep 2010 21:32:58 -0700 (PDT)
> 
> > Applied.
> 
> Btw, I had to apply the following warning fix against your other
> set of changes.

Oh yeah, I only have 32-bits systems at hand so ptrdiff_t == int for me :-(
Sorry.
diff mbox

Patch

diff --git a/net/phonet/socket.c b/net/phonet/socket.c
index 6bf6e3c..aca8fba 100644
--- a/net/phonet/socket.c
+++ b/net/phonet/socket.c
@@ -723,7 +723,8 @@  static int pn_res_seq_show(struct seq_file *seq, void *v)
 		struct sock *sk = *psk;
 
 		seq_printf(seq, "%02X %5d %lu%n",
-			psk - pnres.sk, sock_i_uid(sk), sock_i_ino(sk), &len);
+			   (int) (psk - pnres.sk), sock_i_uid(sk),
+			   sock_i_ino(sk), &len);
 	}
 	seq_printf(seq, "%*s\n", 63 - len, "");
 	return 0;