Question about mpz_clear
Eric M. Hopper
18 Jun 2003 23:08:47 -0500
On Wed, 2003-06-18 at 17:24, Kevin Ryde wrote:
> > Does this clear the memory associated with a given variable zeroed?
Yes, I checked the source after I wrote this. *sheepish grin* I
considered adding the feature, but decided against it.
> > Is there an easy way to make sure it is?
> mp_set_memory_functions will let you have your own free function.
Yes, this is true. I could zero the memory then. I would prefer not to
do it for every variable. Only a few need it. But, since reallocs
happen, it might be best to write my own memory management routines.
> Lots of gmp routines put operand data on the stack too.
That's good to know. Perhaps I will make a function that grabs a 64k
array and fills it with DEADBEEF or 0s it then returns.
I think I will save this problem and put it in the 'to solve later'
category. I'll design around the idea that a solution will eventually
have to be coded, but not implement the solution right off.
There's an excellent C/C++/Python/Unix/Linux programmer with a wide
range of other experience and system admin skills who needs work.
Namely, me. http://www.omnifarious.org/~hopper/resume.html
-- Eric Hopper <email@example.com>
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part
-----BEGIN PGP MESSAGE-----
Version: GnuPG v1.2.1 (GNU/Linux)
-----END PGP MESSAGE-----