Blame SOURCES/autofs-5.1.0-ignore-multiple-commas-in-options-strings.patch

4d476f
autofs-5.1.0 - ignore multiple commas in options strings
4d476f
4d476f
From: Ian Kent <ikent@redhat.com>
4d476f
4d476f
When parsing options strings (such as opts, addopts or remopts) the parser
4d476f
would object to multiple occurrances of the comma character. But this is
4d476f
probably not a significant problem and the parser should just ignore them.
4d476f
---
4d476f
 CHANGELOG           |    1 +
4d476f
 modules/amd_parse.y |    4 ++++
4d476f
 modules/amd_tok.l   |    4 ++--
4d476f
 3 files changed, 7 insertions(+), 2 deletions(-)
4d476f
4d476f
--- autofs-5.0.7.orig/CHANGELOG
4d476f
+++ autofs-5.0.7/CHANGELOG
4d476f
@@ -153,6 +153,7 @@
4d476f
 - fix memory leak in get_defaults_entry().
4d476f
 - fix out of order clearing of options buffer.
4d476f
 - fix reset amd lexer scan buffer.
4d476f
+- ignore multiple commas in options strings.
4d476f
 
4d476f
 25/07/2012 autofs-5.0.7
4d476f
 =======================
4d476f
--- autofs-5.0.7.orig/modules/amd_parse.y
4d476f
+++ autofs-5.0.7/modules/amd_parse.y
4d476f
@@ -465,6 +465,10 @@ options: OPTION
4d476f
 	{
4d476f
 		prepend_opt(opts, $1);
4d476f
 	}
4d476f
+	| OPTION COMMA
4d476f
+	{
4d476f
+		prepend_opt(opts, $1);
4d476f
+	}
4d476f
 	;
4d476f
 
4d476f
 %%
4d476f
--- autofs-5.0.7.orig/modules/amd_tok.l
4d476f
+++ autofs-5.0.7/modules/amd_tok.l
4d476f
@@ -284,9 +284,9 @@ CUTSEP		(\|\||\/)
4d476f
 		return SPACE;
4d476f
 	}
4d476f
 
4d476f
-	":=" { return OPTION_ASSIGN; }
4d476f
+	(:=)(,+)? { return OPTION_ASSIGN; }
4d476f
 
4d476f
-	"," { return COMMA; }
4d476f
+	,+ { return COMMA; }
4d476f
 
4d476f
 	{OPTS} {
4d476f
 		amd_copy_buffer();