On 09/20/2013 01:22 AM, Daiki Ueno wrote: > Hi, > > Regarding the bug report for gettext: > https://lists.gnu.org/archive/html/bug-gettext/2013-09/msg00010.html > > javacomp.c has the following code to check if javac can compile some > Java programs. First, it writes out some code snippet to a temporary > file and then call javac command on the written file. Like this: > > write_temp_file (tmpdir, conftest_file_name, > get_goodcode_snippet (source_version));
> As fopen_temp uses "D" mode on Windows, which implies the file will be > deleted on close (fwriteerror_temp here). Thus, after calling > write_temp_file, the file will be deleted immediately. Maybe we should > use plain fopen/fwriteerror here? That's not the first time I've encountered a problem with mingw's temporary files being deleted on close. See this m4 commit: git.sv.gnu.org/cgit/m4.git/commit/?id=11199a26 So yes, it sounds like we need to avoid temporary files if we want them to persist past the close. Are you up to writing a patch along those lines? -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature