CIFS: Fix ERR_PTR dereference in cifs_get_root
authorPavel Shilovsky <piastryyy@gmail.com>
Sun, 21 Aug 2011 15:30:15 +0000 (19:30 +0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 25 Oct 2011 05:10:15 +0000 (07:10 +0200)
commitf24d5457bd706667951021530dd0590a1f3e9464
tree8547e64f3ee5e9e1a5222d92489c338a42297587
parent726e2766e04f31620d61cbb8bd9fbf7abe962d02
CIFS: Fix ERR_PTR dereference in cifs_get_root

commit 5b980b01212199833ee8023770fa4cbf1b85e9f4 upstream.

move it to the beginning of the loop.

Signed-off-by: Pavel Shilovsky <piastryyy@gmail.com>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Cc: Josh Boyer <jwboyer@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/cifs/cifsfs.c