This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] temporary file handling


Alan,

Thank you for your review!

On Mon, Oct 11, 2010 at 01:38:42PM +1030, Alan Modra wrote:
> Possible free(NULL) here and in make_tempdir, which may crash on some
> older implementations of free.  We seem to worry about that
> possibility elsewhere in binutils.

OK.  With this fixed, would you accept the changes to binutils/bucomm.c?
While unimportant for modern systems that have mkstemp() and mkdtemp(),
these are rather obvious fixes for older systems that only have mktemp().
For example, this:

  tmpname = mktemp (tmpname);
  if (tmpname == NULL)
    return NULL;

was obviously wrong because mktemp() returns an empty string rather than
NULL on error.

Would you like Vasiliy to fix the free(NULL) issue, add a
binutils/ChangeLog entry, and submit just this part of the patch?

> As the libiberty README says, libiberty patch should go to
> gcc-patches@gcc.gnu.org, and maintainers of gcc and binutils generally
> don't like #if 0 to remove code.  Even if this is fixed, I suspect
> your patch will be rejected due to losing the capability to specify a
> temp dir via the temp_base arg of pexecute.

Thank you for explaining this and sharing your opinion.  We'll consider
revising/submitting this part of the patch separately and to the proper
place.

Alexander Peslyak <solar at openwall.com>
http://www.openwall.com - bringing security into open computing environments


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]