Support of multiple symlink levels in command_cd

This commit is contained in:
HonigBij 2015-08-25 13:12:26 +02:00
parent e7ff1d95ac
commit 4afea8b187
1 changed files with 2 additions and 1 deletions

View File

@ -58,7 +58,8 @@ class command_cd(HoneyPotCommand):
newpath = f[A_TARGET]
count += 1
if count > 10:
raise self.fs.TooManyLevels
self.writeln('bash: cd: %s: Too many levels of symbolic links' % path)
return
if not self.fs.is_dir(newpath):
self.writeln('bash: cd: %s: Not a directory' % path)
return