From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <8da7014533355e6d27d723147018a3e8@vitanuova.com> To: 9fans@cse.psu.edu Subject: Re: [9fans] how to avoid a memset() optimization From: rog@vitanuova.com MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Date: Thu, 14 Nov 2002 17:44:11 +0000 Topicbox-Message-UUID: 2020b586-eacb-11e9-9e20-41e7f4b1d025 > memset((volatile void*)p,n,0) would be similar if it were allowed. that's odd. i thought it had originally been suggested that: void f(void) { volatile void *buf = malloc(n); memset(buf, n, 0); } was the "right" way to do it. but now it appears that's not allowed... does that mean that in fact there's *no* portable way of doing it?!