bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Some free()s in module 'relocatable'


From: Eric Blake
Subject: Re: Some free()s in module 'relocatable'
Date: Thu, 10 Jan 2008 06:23:09 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Bruno Haible on 1/10/2008 3:11 AM:
|   /* Memory management: relocate() leaks memory, because it has to construct
|      a fresh pathname.  If this is a problem because your program calls
| !    relocate() frequently, think about caching the result.  Or free the
| !    return value if it was different from the argument pathname.  */

The first sentence is no longer true - since you provide a way to
determine if memory was allocated, there is no leak.  Rather, I would
s/leaks memory/potentially allocates memory/.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD4DBQFHhhw984KuGfSFAYARAl0oAJ923wEqd80HrJhSdk3B3VZa3eBF6QCXW5E0
kUFtTQ5iHxbUEYTvddIprg==
=u49K
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]