We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
From 35de0cd724826bc02d4727b1d2cda6e18e89d2bd Mon Sep 17 00:00:00 2001 Message-Id: <35de0cd724826bc02d4727b1d2cda6e18e89d2bd.1509107750.git.hahn@univention.de> From: Philipp Hahn <[email protected]> Date: Fri, 27 Oct 2017 14:05:07 +0200 Subject: [PATCH] nsswitch.conf: Handle EOL comment #517 Organization: Univention GmbH, Bremen, Germany nsswitch.conf database statements may contain comments at end of line. --- lenses/nsswitch.aug | 2 +- lenses/tests/test_nsswitch.aug | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lenses/nsswitch.aug b/lenses/nsswitch.aug index 2d65345a..5f9e7171 100644 --- a/lenses/nsswitch.aug +++ b/lenses/nsswitch.aug @@ -69,7 +69,7 @@ let database = . (Build.opt_list (service|reaction) Sep.space) - . Util.eol ] + . Util.comment_or_eol ] (* View: lns *) let lns = ( empty | comment | database )* diff --git a/lenses/tests/test_nsswitch.aug b/lenses/tests/test_nsswitch.aug index c9c57472..b467cf77 100644 --- a/lenses/tests/test_nsswitch.aug +++ b/lenses/tests/test_nsswitch.aug @@ -8,6 +8,7 @@ networks: nis [!UNAVAIL=return success=continue] files protocols: db files netgroup: nis bootparams: nisplus [NOTFOUND=return] files +aliases: files # uses by mail sudoers: files ldap " @@ -44,6 +45,9 @@ test Nsswitch.lns get conf = { "status" = "NOTFOUND" { "action" = "return" } } } { "service" = "files" } } + { "database" = "aliases" + { "service" = "files" } + { "#comment" = "uses by mail" } } { "database" = "sudoers" { "service" = "files" } { "service" = "ldap" } } -- 2.11.0
The text was updated successfully, but these errors were encountered:
9295df4
Thanks a ton for the patch !
Sorry, something went wrong.
No branches or pull requests
The text was updated successfully, but these errors were encountered: