Mail Archives: djgpp/2000/08/21/03:49:51
> From: "ObiGuan Kenobi" <jgfw AT iname DOT com>
> Date: Mon, 21 Aug 2000 03:23:05 +0800
>
> It seems that _rename( ) function from libc has some problems
Okay, that much I expected. But it still doesn't tell enough to know
how to correct this. We need more info, see below.
> And one thing I forgotten to tell you. Windows ME uses DOS 8.0,
> rather than DOS 7.1 that Win95b and Win98 uses.
Thanks for the info. This shouldn't by itself cause problems, though,
since all versions above 7.0 are treated the same, provided the
version isn't 10.x (which is reserved by OS/2's DOS emulation).
> Not just stubify.exe is effected but ar.exe which uses _rename () is
> effected too.
What ar command line fails, and with what error message?
> This is what I found out. I think the _rename( ) function has no
> problem renaming from filename X to Y if Y doesn't exist. If Y
> exist, then _rename() will fail.
I need to know where exactly does _rename fail, and why. Please take
a look at _rename's source near line 110: if the file Y already
exists, it deletes it and tries again. Please step with GDB through
that code and see what isn't working.
It's possible that it will be easier for you to compile _rename.c with
-DTEST and use the small test program produced by that to look into
this. That is, use the following commands:
gcc -DTEST -g -o _rename _rename.c
gdb _rename.exe
break _rename
run test.000 test.001
(assuming test.001 already exists).
Once again, thanks for working on this.
- Raw text -