Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Mar 2004 21:50:54 +0300
From:      Roman Bogorodskiy <bogorodskiy@inbox.ru>
To:        John Baldwin <jhb@FreeBSD.org>
Cc:        freebsd-hackers@FreeBSD.org
Subject:   Re: kernel modules programming: struct proc question
Message-ID:  <20040317185054.GB635@lame.novel.ru>
In-Reply-To: <200403171017.21776.jhb@FreeBSD.org>
References:  <20040316163956.GD638@lame.novel.ru> <200403171017.21776.jhb@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--yNb1oOkm5a9FJOVX
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

 John wrote:

> Also, you might consider using strncmp() to make the code a bit easier to=
=20
> read, i.e.:
>=20
> 	if (strncmp(name, "/tmp/", 5) =3D=3D 0)
> 		printf("open(2): %s by pid %d (%s)\n", name, td->td_proc->p_pid,
> 		    td->td_proc->p_comm);

Thank you very much, it works.=20

-Roman Bogorodskiy


--yNb1oOkm5a9FJOVX
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (FreeBSD)

iQEVAwUBQFieDipMDQ8aPhy0AQK47wf/TgDsObv6zSAm+TvAb+JmJT4ARQtxFq/e
TDRG1zFryDqYd6Mf/Y9uSf66O0flPDosZ9VyYF1H1BJJCvk505EkqhqYrqfr4GLC
zLIJEQVPWS4RF2cNlAxFb0LAABT2iQDMjbF9jl9cN1C+9QXdr4KlS2nVjPd/KBFY
DYY1blQ4QytrMJ/huJJJzQ6BlnoliFy7sz0nGNl7TB8FO1/3fAjUcQe1+XjBwujQ
T2NkNMPPmvOcathxnpLfPY0dWYSAYvJuZJTKWYTE7SNF4v2oRWRbIFXu88j+cz3M
LKlXTo8GUUfU1i+YCNOPS4UNwfa/9R3c1ERzRSEpo1vDRqLzVqIBTg==
=SJ5d
-----END PGP SIGNATURE-----

--yNb1oOkm5a9FJOVX--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040317185054.GB635>