public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Raj <obelix123@toughguy.net>
To: Willy Tarreau <willy@w.ods.org>
Cc: Javier Govea <jgovea@magma.ca>, linux-kernel@vger.kernel.org
Subject: Re: Source ports at the  IP layer
Date: Wed, 15 Oct 2003 12:27:18 +0530	[thread overview]
Message-ID: <3F8CEFCE.33EF6836@toughguy.net> (raw)
In-Reply-To: 20031014214231.GC16761@alpha.home.local



> > I also tried
> > struct tcphdr *th = (struct tcphdf *)skb->h.th;
> > and then printing out th->source...but i'm still getting 17664...any suggestion on how I
> > can get the ports??? All ideas are very very welcome...

A weird wild guess :-) . Possibly the source port is still in
network-byte-order. Try converting it to host-byte-order ( if your
machine arch is little-endian ) before printing. 

Network-byte-order 17664 = 69 in little-endian which is tftp.

/Raj

      reply	other threads:[~2003-10-15  6:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-14 21:13 Source ports at the IP layer Javier Govea
2003-10-14 21:42 ` Willy Tarreau
2003-10-15  6:57   ` Raj [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3F8CEFCE.33EF6836@toughguy.net \
    --to=obelix123@toughguy.net \
    --cc=jgovea@magma.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=willy@w.ods.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox