From 58e0d96396c2b68050a33aae8458360eb9bbc0b4 Mon Sep 17 00:00:00 2001 From: Nicolas Dandrimont Date: Tue, 6 Mar 2012 21:14:03 +0100 Subject: [PATCH] =?UTF-8?q?[chsh]=20les=20shells=20n'ont=20pas=20de=20\n?= =?UTF-8?q?=20=C3=A0=20la=20fin?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ignore-this: 1fd0cd4f389b0a3a2b8b47d5cc9c9d9 darcs-hash:20120306201403-ffbb2-84be04aa8e6eb912c2f9c8c0f9ccd7b3f4099fd7.gz --- gestion/chsh.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gestion/chsh.py b/gestion/chsh.py index 75eda1ea..e5b11837 100644 --- a/gestion/chsh.py +++ b/gestion/chsh.py @@ -38,7 +38,7 @@ fd=open('/etc/shells') lines=fd.readlines() fd.close() -shells = [line for line in lines if not (line.startswith('#') or line.endswith('/rssh'))] +shells = [line.strip() for line in lines if not (line.startswith('#') or line.endswith('/rssh'))] if not shell in shells: print 'Shell invalide. Les shells valides sont :'