Browse Source

Regex escaping patch by rse.engelschall

git-svn-id: https://klish.googlecode.com/svn/trunk@535 0eaa4687-2ee9-07dd-09d9-bcdd2d2dd5fb
Serj Kalichev 12 years ago
parent
commit
74f65b3621
2 changed files with 2 additions and 2 deletions
  1. 1 1
      clish/shell/shell_new.c
  2. 1 1
      clish/shell/shell_tinyxml.cpp

+ 1 - 1
clish/shell/shell_new.c

@@ -78,7 +78,7 @@ static void clish_shell_init(clish_shell_t * this,
 	/* Args */
 	tmp_ptype = clish_shell_find_create_ptype(this,
 		"internal_ARGS",
-		"Arguments", "[^\\]+",
+		"Arguments", "[^\\\\]+",
 		CLISH_PTYPE_REGEXP,
 		CLISH_PTYPE_NONE);
 	assert(tmp_ptype);

+ 1 - 1
clish/shell/shell_tinyxml.cpp

@@ -410,7 +410,7 @@ process_param(clish_shell_t * shell, TiXmlElement * element, void *parent)
 				&shell->ptype_tree, ptype_name);
 			if (!tmp)
 				tmp = clish_shell_find_create_ptype(shell,
-					ptype_name, "Option", "[^\\]+",
+					ptype_name, "Option", "[^\\\\]+",
 					CLISH_PTYPE_REGEXP, CLISH_PTYPE_NONE);
 			assert(tmp);
 			opt_param = clish_param_new(prefix, help, tmp);