This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: PATCH: Parallel compilation of class files
- From: Mark Mitchell <mark at codesourcery dot com>
- To: Alexandre Oliva <aoliva at redhat dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, "java at gcc dot gnu dot org" <java at gcc dot gnu dot org>
- Date: Sun, 12 May 2002 13:41:11 -0700
- Subject: Re: PATCH: Parallel compilation of class files
--On Wednesday, May 08, 2002 10:41:37 PM -0300 Alexandre Oliva
<aoliva@redhat.com> wrote:
> On May 8, 2002, Mark Mitchell <mark@codesourcery.com> wrote:
>
>> ! temporary_file_name = xmalloc (strlen (class_file_name)
>> ! + strlen (".tmp") + 1);
>> ! sprintf (temporary_file_name, "%s.tmp", class_file_name);
>
> Consider using `concat (class_file_name, ".tmp");'
>
>> ! if (rename (temporary_file_name, class_file_name) == -1)
>> ! fatal_io_error ("can't create %s", class_file_name);
>
> wouldn't it be appropriate to unlink the temporary file in this case?
Both good suggestions; I'll kick off tests now.
--
Mark Mitchell mark@codesourcery.com
CodeSourcery, LLC http://www.codesourcery.com