lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <480E29CD.1010203@sandeen.net>
Date:	Tue, 22 Apr 2008 13:09:17 -0500
From:	Eric Sandeen <sandeen@...deen.net>
To:	Joe Perches <joe@...ches.com>
CC:	Ingo Molnar <mingo@...e.hu>,
	linux-kernel Mailing List <linux-kernel@...r.kernel.org>,
	Arjan van de Ven <arjan@...radead.org>,
	Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH] Fix  max-stack calculators to skip canary

Joe Perches wrote:

> Wouldn't it be better to have exactly the same code?
> How about using a statement expression macro?
> 
> #define DEBUG_STACK_FREE(process) \
> ({ \
> 	unsigned long *n = end_of_stack(process); \
> 	do { 	/* Skip over canary */\
> 		n++; \
> 	} while (!*n); \
> 	(unsigned long)n - (unsigned long)end_of_stack(process); \
> })
> 

That'd probably be good although I don't think we like macros anymore :)

-Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ