]> git.pld-linux.org Git - packages/db.git/blob - patch.4.1.24.3
- fixed optflags passing, release 5
[packages/db.git] / patch.4.1.24.3
1 *** os_win32/os_rename.c.orig   2002/07/12 18:56:55     1.12
2 --- os_win32/os_rename.c        2002/09/25 04:15:41     1.13
3 ***************
4 *** 24,30 ****
5         u_int32_t flags;
6   {
7         int ret;
8 -       char oldbuf[MAX_PATH], newbuf[MAX_PATH];
9   
10         ret = 0;
11         if (DB_GLOBAL(j_rename) != NULL) {
12 --- 24,29 ----
13 ***************
14 *** 45,65 ****
15                 } else {
16                         /*
17                          * There is no MoveFileEx for Win9x/Me, so we have to
18 !                        * do the best we can.
19                          */
20 -                       if (!GetLongPathName(oldname, oldbuf, sizeof oldbuf) ||
21 -                           !GetLongPathName(newname, newbuf, sizeof newbuf)) {
22 -                               ret = __os_win32_errno();
23 -                               goto done;
24 -                       }
25
26 -                       /*
27 -                        * If the old and new names differ only in case, we're
28 -                        * done.
29 -                        */
30 -                       if (strcasecmp(oldbuf, newbuf) == 0)
31 -                               goto done;
32
33                         (void)DeleteFile(newname);
34                         if (!MoveFile(oldname, newname))
35                                 ret = __os_win32_errno();
36 --- 44,53 ----
37                 } else {
38                         /*
39                          * There is no MoveFileEx for Win9x/Me, so we have to
40 !                        * do the best we can.  Note that MoveFile returns 1
41 !                        * if the names refer to the same file, so we don't
42 !                        * need to check that here.
43                          */
44                         (void)DeleteFile(newname);
45                         if (!MoveFile(oldname, newname))
46                                 ret = __os_win32_errno();
This page took 0.076034 seconds and 3 git commands to generate.