Re: commit 64ff3b938ec6782e6585a83d5459b98b0c3f6eb8 breaks rlogin

From: Jeff Chua
Date: Mon Feb 09 2009 - 09:10:49 EST


On Mon, Feb 9, 2009 at 3:13 PM, Ilpo Järvinen <ilpo.jarvinen@xxxxxxxxxxx> wrote:
> net/ipv4/tcp_output.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c
> index 557fe16..c808d73 100644
> --- a/net/ipv4/tcp_output.c
> +++ b/net/ipv4/tcp_output.c
> @@ -667,7 +667,8 @@ static int tcp_transmit_skb(struct sock *sk, struct sk_buff *skb, int clone_it,
> if (between(tp->snd_up, tcb->seq + 1, tcb->seq + 0xFFFF)) {
> th->urg_ptr = htons(tp->snd_up - tcb->seq);
> th->urg = 1;
> - } else if (after(tcb->seq + 0xFFFF, tp->snd_nxt)) {
> + } else if (after(tcb->seq + 0xFFFF, tp->snd_nxt) &&
> + before(tcb->seq, tcp->snd_up)) {
> th->urg_ptr = 0xFFFF;
> th->urg = 1;
> }
> --
> 1.5.6.5
>

Ilpo,

Got this error ...

CC net/ipv4/tcp_output.o
net/ipv4/tcp_output.c: In function 'tcp_transmit_skb':
net/ipv4/tcp_output.c:671: error: 'tcp' undeclared (first use in this function)
net/ipv4/tcp_output.c:671: error: (Each undeclared identifier is
reported only once
net/ipv4/tcp_output.c:671: error: for each function it appears in.)

> + before(tcb->seq, tcp->snd_up)) {

That should be "tp->snd_up" instead of "tcp->snd_up". Other than that,
the good news is I've tested your patch on top of Herbert's patch, and
it works! No more rlogin hangs!

Thanks,
Jeff.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/