User1 connects, creates directory abc and changes current directory to abc
User2 connects, deletes directory abc
User1 attempts to do some action with his current directory (e.g. upload a file)
DirectoryNotFoundException is thrown and 501 Syntax error in parameters or arguments. is returned to User1
Affected commands:
At least PWD, CWD, STOR
Log with full exception:
[LOG - 192,168,1,121,205,45] [TRC] STOR cam2_802814741_20180421185452334_MOTION_DETECTION.jpg
[LOG - 192,168,1,121,205,45] [DBG] 150 Opening connection for data transfer.
[LOG - 192,168,1,121,205,45] [ERR] Error while processing background command STOR cam2_802814741_20180421185452334_MOTION_DETECTION.jpg
[LOG - 192,168,1,121,205,45] [EXP] System.AggregateException: One or more errors occurred. ---> System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\aa\bb\cc\192.168.1.121\2018_04_21-2018_04_21\cam2_802814741_20180421185452334_MOTION_DETECTION.jpg'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
at System.IO.FileInfo.Create()
at FubarDev.FtpServer.FileSystem.DotNet.DotNetFileSystem.<CreateAsync>d__23.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at FubarDev.FtpServer.CommandHandlers.StorCommandHandler.<Process>d__3.MoveNext()
--- End of inner exception stack trace ---
---> (Inner Exception #0) System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\aa\bb\cc\192.168.1.121\2018_04_21-2018_04_21\cam2_802814741_20180421185452334_MOTION_DETECTION.jpg'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
at System.IO.FileInfo.Create()
at FubarDev.FtpServer.FileSystem.DotNet.DotNetFileSystem.<CreateAsync>d__23.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at FubarDev.FtpServer.CommandHandlers.StorCommandHandler.<Process>d__3.MoveNext()<---
[LOG - 192,168,1,121,205,45] [WRN] 501 Syntax error in parameters or arguments.
Steps to reproduce:
abc
and changes current directory toabc
abc
DirectoryNotFoundException
is thrown and501 Syntax error in parameters or arguments.
is returned to User1Affected commands: At least PWD, CWD, STOR
Log with full exception: