To: vim-dev@vim.org Subject: Patch 6.1.043 Fcc: outbox From: Bram Moolenaar MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.1.043 Problem: After patch 6.1.040 a few warnings are produced. Solution: Add a type cast to "char *" for mch_chdir(). (Axel Kielhorn) Files: src/diff.c, src/ex_docmd.c.c, src/misc1.c, src/os_unix.c *** ../vim61.042/src/diff.c Mon Apr 29 21:59:52 2002 --- src/diff.c Wed May 1 19:35:20 2002 *************** *** 782,788 **** * have our own temp dir use that instead, it will be cleaned up when we * exit (any .rej files created). Don't change directory if we can't * return to the current. */ ! if (mch_dirname(dirbuf, MAXPATHL) != OK || mch_chdir(dirbuf) != 0) dirbuf[0] = NUL; else { --- 782,788 ---- * have our own temp dir use that instead, it will be cleaned up when we * exit (any .rej files created). Don't change directory if we can't * return to the current. */ ! if (mch_dirname(dirbuf, MAXPATHL) != OK || mch_chdir((char *)dirbuf) != 0) dirbuf[0] = NUL; else { *** ../vim61.042/src/ex_docmd.c Mon Apr 29 21:59:52 2002 --- src/ex_docmd.c Wed May 1 19:33:37 2002 *************** *** 6690,6696 **** * Change to session file's dir. */ if (mch_dirname(dirnow, MAXPATHL) == FAIL ! || mch_chdir(dirnow) != 0) *dirnow = NUL; if (*dirnow != NUL && (ssop_flags & SSOP_SESDIR)) { --- 6690,6696 ---- * Change to session file's dir. */ if (mch_dirname(dirnow, MAXPATHL) == FAIL ! || mch_chdir((char *)dirnow) != 0) *dirnow = NUL; if (*dirnow != NUL && (ssop_flags & SSOP_SESDIR)) { *** ../vim61.042/src/misc1.c Mon Apr 29 21:59:52 2002 --- src/misc1.c Wed May 1 19:36:00 2002 *************** *** 2825,2831 **** * Change to the directory and get the actual path. This resolves * links. Don't do it when we can't return. */ ! if (mch_dirname(NameBuff, MAXPATHL) == OK && mch_chdir(NameBuff) == 0) { if (!mch_chdir((char *)var) && mch_dirname(IObuff, IOSIZE) == OK) var = IObuff; --- 2825,2832 ---- * Change to the directory and get the actual path. This resolves * links. Don't do it when we can't return. */ ! if (mch_dirname(NameBuff, MAXPATHL) == OK ! && mch_chdir((char *)NameBuff) == 0) { if (!mch_chdir((char *)var) && mch_dirname(IObuff, IOSIZE) == OK) var = IObuff; *** ../vim61.042/src/os_unix.c Mon Apr 29 21:59:52 2002 --- src/os_unix.c Wed May 1 19:36:25 2002 *************** *** 1999,2005 **** fd < 0 && #endif (mch_dirname(olddir, MAXPATHL) == FAIL ! || mch_chdir(olddir) != 0)) { p = NULL; /* can't get current dir: don't chdir */ retval = FAIL; --- 1999,2005 ---- fd < 0 && #endif (mch_dirname(olddir, MAXPATHL) == FAIL ! || mch_chdir((char *)olddir) != 0)) { p = NULL; /* can't get current dir: don't chdir */ retval = FAIL; *** ../vim61.042/src/version.c Tue Apr 30 16:50:20 2002 --- src/version.c Wed May 1 19:38:39 2002 *************** *** 608,609 **** --- 608,611 ---- { /* Add new patch number below this line */ + /**/ + 43, /**/ -- Why isn't there mouse-flavored cat food? /// Bram Moolenaar -- Bram@moolenaar.net -- http://www.moolenaar.net \\\ /// Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim \\\ \\\ Project leader for A-A-P -- http://www.a-a-p.org /// \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org ///