PATCH: java/25330: A race condition in write_classfile
Andrew Haley
aph@redhat.com
Mon Dec 12 11:21:00 GMT 2005
H. J. Lu writes:
> With parallel build in libjava, several processes may want to generate
> the same class file. They are using the same temporary class file. They
> may override each other. This patch uses PID in temporary class file
> to avoid it.
>
> H.J.
> ---
> 2005-12-10 H.J. Lu <hongjiu.lu@intel.com>
>
> PR java/25330
> * jcf-write.c (write_classfile): Use PID in temporary class
> file. Save/restore errno when reporting error.
OK, thanks.
I did wonder if getpid() was perhaps not part of the OS support that
we assume to be present, but it's used without any guard in toplev.c,
so it must be fine to use it here too.
Andrew.
More information about the Java-patches
mailing list