From: Subrata M. <su...@li...> - 2009-12-03 15:13:09
|
On Tue, 2009-12-01 at 23:22 +0100, Jiri Palecek wrote: > Hello, > > this patch silences the error message "mkdir: directory already exists" in ssh tests, caused by the code that handles home directory creation in case adduser didn't do it. Unfortunately, the same code failed when adduser did create the directory. > > Regards > Jiri Palecek > > Signed-off-by: Jiri Palecek <jpa...@we...> Thanks. Regards-- Subrata > --- > testcases/network/tcp_cmds/ssh/ssh01 | 2 +- > testcases/network/tcp_cmds/ssh/ssh02 | 2 +- > testcases/network/tcp_cmds/ssh/ssh03 | 2 +- > 3 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/testcases/network/tcp_cmds/ssh/ssh01 b/testcases/network/tcp_cmds/ssh/ssh01 > index 657449a..718f198 100755 > --- a/testcases/network/tcp_cmds/ssh/ssh01 > +++ b/testcases/network/tcp_cmds/ssh/ssh01 > @@ -57,7 +57,7 @@ do_setup() > # in adduser) > USER_UID=$(id -u $TEST_USER) > USER_GID=$(id -g $TEST_USER) > - if ! mkdir "$TEST_USER_HOMEDIR"; then > + if ! mkdir -p "$TEST_USER_HOMEDIR"; then > end_testcase "Failed to create $TEST_USER_HOMEDIR" > fi > chown -Rf $USER_UID.$USER_GID "$TEST_USER_HOMEDIR" > diff --git a/testcases/network/tcp_cmds/ssh/ssh02 b/testcases/network/tcp_cmds/ssh/ssh02 > index 84c3637..a9974a0 100755 > --- a/testcases/network/tcp_cmds/ssh/ssh02 > +++ b/testcases/network/tcp_cmds/ssh/ssh02 > @@ -59,7 +59,7 @@ do_setup() > # in adduser) > USER_UID=$(id -u $TEST_USER) > USER_GID=$(id -g $TEST_USER) > - if ! mkdir "$TEST_USER_HOMEDIR"; then > + if ! mkdir -p "$TEST_USER_HOMEDIR"; then > end_testcase "Failed to create $TEST_USER_HOMEDIR" > fi > chown -R $USER_UID.$USER_GID "$TEST_USER_HOMEDIR" > diff --git a/testcases/network/tcp_cmds/ssh/ssh03 b/testcases/network/tcp_cmds/ssh/ssh03 > index 5c7305e..927db76 100755 > --- a/testcases/network/tcp_cmds/ssh/ssh03 > +++ b/testcases/network/tcp_cmds/ssh/ssh03 > @@ -58,7 +58,7 @@ do_setup() > # in adduser) > USER_UID=$(id -u $TEST_USER) > USER_GID=$(id -g $TEST_USER) > - if ! mkdir "$TEST_USER_HOMEDIR"; then > + if ! mkdir -p "$TEST_USER_HOMEDIR"; then > end_testcase "Failed to create $TEST_USER_HOMEDIR" > fi > chown -R $USER_UID.$USER_GID "$TEST_USER_HOMEDIR" |