summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorArthur de Jong <arthur@arthurdejong.org>2008-12-03 22:45:20 +0000
committerArthur de Jong <arthur@arthurdejong.org>2008-12-03 22:45:20 +0000
commitc0f408747204aba0050d4545b7da90ea7961063d (patch)
tree3d1c703e1f82f1d08eb3f030cee48e868d7f826b /tests
parent62928b08bb311646c6b6ee5c244bf27bde6d32d1 (diff)
allow backslashes in names execpt as first or last character
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@804 ef36b2f9-881f-0410-afb5-c4e39611909c
Diffstat (limited to 'tests')
-rw-r--r--tests/test_common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/test_common.c b/tests/test_common.c
index fa70b6d..d8aa35b 100644
--- a/tests/test_common.c
+++ b/tests/test_common.c
@@ -39,6 +39,9 @@ static void test_isvalidname(void)
assert(!isvalidname("-arthur"));
assert(isvalidname("arthur-is-nice"));
assert(isvalidname("sambamachine$"));
+ assert(isvalidname("foo\\bar"));
+ assert(!isvalidname("\\foo\\bar"));
+ assert(!isvalidname("foo\\bar\\"));
}
/* the main program... */