Re: Make g_rename() replace existing files on Win32?
- From: Tor Lillqvist <tml iki fi>
- To: gtk-devel-list gnome org
- Subject: Re: Make g_rename() replace existing files on Win32?
- Date: Thu, 1 Dec 2005 15:41:51 +0200
J. Ali Harlow writes:
> The advantages outweigh the tiny API breakage.
Yup. And especially as I finally found out that one of the reasons why
Evolution's "on this machine" folders never showed up on Win32 was
partially because of this rename() issue, I went ahead with the change.
At the same time I also fixed the Win32 implementation of g_stat() to
strip trailing slashes as necessary. (Sounds incredible, but yes,
otherwise the stat() in Microsoft's C library fails. For instance
stat("c:\\windows\\", &st) fails but stat("c:\\windows", &st) works
ok.) This was the other cause for the local folders not to show up in
Evo... It is just too much hassle to require callers of g_stat() to
strip away such trailing nonsignificant slashes themselves (and at the
same time be careful enough not to remove the slash from the root of a
drive, like "c:/").
--tml
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]