3 ms·
Even if you don't do something like that a modern C compiler will do all sorts of things behind your back. Like removing null checks[1] or pointer overflow chec
by anon1385 13y ago
Even if you don't do something like that a modern C compiler will do all sorts of things behind your back. Like removing null checks[1] or pointer overflow checks[2]
[1] http://www.cvedetails.com/cve/CVE-2009-1897 http://www.cvedetails.com/cve/CVE-2009-1897
[2] http://www.cvedetails.com/cve/CVE-2008-1685 http://www.cvedetails.com/cve/CVE-2008-1685
- rapala 13y agoWell, to be fair, the NULL check was in a wrong place. The pointer was already dereferenced before the check. struct tun_struct *tun = __tun_get(tfile); struct sock *sk = tun->sk; unsigned int mask = 0; if (!tun) return POLLERR;