From: jones.ian@comcast.net ("Ian Jones")
To: Eric Leblond <eric@regit.org>
Cc: netfilter-devel@lists.netfilter.org
Subject: Re: libipq and timestamp
Date: Mon, 18 Aug 2003 19:37:47 -0500 [thread overview]
Message-ID: <r83i4h44.fsf@comcast.net> (raw)
In-Reply-To: <1061213776.21582.9.camel@tech004.alphalink.fr> (Eric Leblond's message of "18 Aug 2003 15:36:17 +0200")
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Eric Leblond <eric@regit.org> writes:
> I did not manage to get the timestamp of a packet in the message given
> by libipq. It is just 0.
> Is there something to do to have it fill in ?
If the packet is locally generated then the timestamp is not filled
in for you. Here is a snippet that may help:
/* locally generated?, no timestamp */
if (!m->timestamp_sec)
{
memset (&tz, 0, sizeof (tz));
gettimeofday (&tv, &tz);
ph.ts.tv_sec = tv.tv_sec;
ph.ts.tv_usec = tv.tv_usec;
}
else
{
ph.ts.tv_sec = m->timestamp_sec;
ph.ts.tv_usec = m->timestamp_usec;
}
-----BEGIN PGP SIGNATURE-----
Comment: Keeping the world safe for geeks.
iD8DBQE/QXFbwBVKl/Nci0oRAt91AJwMLTu43iFjrtAyAj4fGG2nvYK2pwCg7RgH
ym7QrHv/NkFEa3Q/semyoS4=
=fwjd
-----END PGP SIGNATURE-----
prev parent reply other threads:[~2003-08-19 0:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-18 13:36 libipq and timestamp Eric Leblond
2003-08-19 0:37 ` "Ian Jones" [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=r83i4h44.fsf@comcast.net \
--to=jones.ian@comcast.net \
--cc=eric@regit.org \
--cc=netfilter-devel@lists.netfilter.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.