* remote-fileio.c (remote_fileio_func_rename): Use Cygwin 1.7
[binutils-gdb.git] / gdb / remote-fileio.c
index d7215fe605b00e9e2d41c063d59e901bd8290599..4f775ada972333fac12cf498bfcb027e080fe51e 100644 (file)
@@ -1021,12 +1021,14 @@ remote_fileio_func_rename (char *buf)
                errno = EISDIR;
              else
                {
-                 char oldfullpath[PATH_MAX + 1];
-                 char newfullpath[PATH_MAX + 1];
+                 char oldfullpath[PATH_MAX];
+                 char newfullpath[PATH_MAX];
                  int len;
 
-                 cygwin_conv_to_full_posix_path (oldpath, oldfullpath);
-                 cygwin_conv_to_full_posix_path (newpath, newfullpath);
+                 cygwin_conv_path (CCP_WIN_A_TO_POSIX, oldpath, oldfullpath,
+                                   PATH_MAX);
+                 cygwin_conv_path (CCP_WIN_A_TO_POSIX, newpath, newfullpath,
+                                   PATH_MAX);
                  len = strlen (oldfullpath);
                  if (newfullpath[len] == '/'
                      && !strncmp (oldfullpath, newfullpath, len))