This repository was archived by the owner on Jul 8, 2020. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -343,10 +343,21 @@ func (cmd commandList) RequireAuth() bool {
343343
344344func (cmd commandList ) Execute (conn * Conn , param string ) {
345345 conn .writeMessage (150 , "Opening ASCII mode data connection for file list" )
346- fpath := param
347- if param == "-l" {
348- fpath = conn .namePrefix
346+ var fpath string
347+ if len (param ) == 0 {
348+ fpath = param
349+ } else {
350+ fields := strings .Fields (param )
351+ for _ , field := range fields {
352+ if strings .HasPrefix (field , "-" ) {
353+ //TODO: currently ignore all the flag
354+ fpath = conn .namePrefix
355+ } else {
356+ fpath = field
357+ }
358+ }
349359 }
360+
350361 path := conn .buildPath (fpath )
351362 info , err := conn .driver .Stat (path )
352363 if err != nil {
You can’t perform that action at this time.
0 commit comments