Date: Sat, 14 Jun 2008 21:43:06 +0200 From: Patrick =?ISO-8859-15?Q?Lamaizi=E8re?= <patfbsd@davenulle.org> To: freebsd-hackers@freebsd.org Subject: padlock(4) bug or feature ? Message-ID: <20080614214306.079e279f@baby-jane-lamaiziere-net.local>
next in thread | raw e-mail | index | archive | help
Hello, I was looking the code of padlock(4). In padlock_newsession(), when there is an error we call padlock_freesession with dev == NULL by sample : error = padlock_cipher_setup(ses, encini); if (error != 0) { padlock_freesession(NULL, ses->ses_id); return (error); But padlock_freesession() uses dev to get the softc. static int padlock_freesession(device_t dev, uint64_t tid) { struct padlock_softc *sc = device_get_softc(dev) I'm asking how it can work with dev == NULL ? Regards.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080614214306.079e279f>