From 346893dbef4b4697e3efbffd05d9de94d93263c3 Mon Sep 17 00:00:00 2001 From: Tomas Mraz Date: Fri, 27 May 2005 10:33:14 +0000 Subject: Relevant BUGIDs: Purpose of commit: new feature Commit summary: --------------- * pam_access: Add listsep option to set list element separator by Richard Shaffer --- modules/pam_access/pam_access.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/pam_access/pam_access.c b/modules/pam_access/pam_access.c index 4f6cf574..797e7160 100644 --- a/modules/pam_access/pam_access.c +++ b/modules/pam_access/pam_access.c @@ -86,7 +86,7 @@ /* Delimiters for fields and for lists of users, ttys or hosts. */ static const char *fs = ":"; /* field separator */ -static const char sep[] = ", \t"; /* list-element separator */ +static const char *sep = ", \t"; /* list-element separator */ /* Constants to be used in assignments only, not in comparisons... */ @@ -129,6 +129,11 @@ static int parse_args(struct login_info *loginfo, int argc, const char **argv) /* the admin wants to override the default field separators */ fs = argv[i]+9; + } else if (!strncmp("listsep=", argv[i], 8)) { + + /* the admin wants to override the default list separators */ + sep = argv[i]+8; + } else if (!strncmp("accessfile=", argv[i], 11)) { FILE *fp = fopen(11 + argv[i], "r"); -- cgit v1.2.3