diff src/misc2.c @ 14905:c1e94bb0f004 v8.1.0464

patch 8.1.0464: MS-Windows: job_info() has cmd without backslashes commit https://github.com/vim/vim/commit/1df2fa47b49dae568af6048b1dce1edbf4eee7e7 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Oct 7 21:36:11 2018 +0200 patch 8.1.0464: MS-Windows: job_info() has cmd without backslashes Problem: MS-Windows: job_info() has cmd without backslashes. (Daniel Hahler) Solution: Use rem_backslash(). (closes #3517, closes #3404)
author Bram Moolenaar <Bram@vim.org>
date Sun, 07 Oct 2018 21:45:04 +0200
parents 27b9a84395b5
children 69d2749a6a2f
line wrap: on
line diff
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -6458,14 +6458,14 @@ mch_parse_cmd(char_u *cmd, int use_shcf,
 	    while (*p != NUL && (inquote || (*p != ' ' && *p != TAB)))
 	    {
 		if (p[0] == '"')
-		    /* quotes surrounding an argument and are dropped */
+		    // quotes surrounding an argument and are dropped
 		    inquote = !inquote;
 		else
 		{
-		    if (p[0] == '\\' && p[1] != NUL)
+		    if (rem_backslash(p))
 		    {
-			/* First pass: skip over "\ " and "\"".
-			 * Second pass: Remove the backslash. */
+			// First pass: skip over "\ " and "\"".
+			// Second pass: Remove the backslash.
 			++p;
 		    }
 		    if (i == 1)