VanDyke Software Forums

Go Back   VanDyke Software Forums > File Transfer
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
  #1  
Old 03-23-2012, 11:53 AM
dthompto dthompto is offline
Registered User
 
Join Date: Jan 2009
Posts: 3
SecureFX command line utility question

Trying to get multiple files and seeing what looks to me like strange behavior when using a wild card (*). If the file(s) exist we do get them, if not we still get a errorlevel code 0 indicating success when we want a non-zero code.

sfxcl.exe sftp://myuser@my.server/filename-*.zip E:\Test

Directory listing completed.
Transfer(00000001): SUMMARY: Attempted to transfer 0 files.
Transfer(00000001): SUMMARY: Transferred 0 files successfully.
Channel Closed.

c:\>echo %errorlevel%
0

If I remove the wild card, and the file is not there I do get a non-zero code.

sfxcl.exe sftp://myuser@my.server/filename-.zip E:\Test

Beginning transfer.
Changing directories...
Transfer(00000001): SEND : Stat /path/to/file/filename-.zip
Transfer(00000001): The system cannot find the file specified.

Changing directories...
Checking source file status...
Transfer(00000001): SEND : Stat /path/to/file/filename-.zip
Transfer(00000001): Opening file 'filename-.zip' for download as 'filename-.zip'.
Opening file ...
Transferring file ...
Transfer(00000001): SEND : Open: /path/to/file/filename-.zip, mode 0x1
Destination file closed.
Failed to open remote file...
Transfer(00000001): File filename-.zip could not be opened by server: The system cannot find the file specified.

Transfer(00000001): SUMMARY: Attempted to transfer 1 files.
Transfer(00000001): SUMMARY: Transferred 0 files successfully.
Transfer(00000001): SUMMARY: filename-.zip: Unable to open source file.
Transfer(00000001): SUMMARY: filename-.zip: File filename-.zip could not be opened by server: The system cannot find the file specified.
File filename-.zip could not be opened by server.

The system cannot find the file specified.

The file will not be transferred.
Channel Closed.

c:\>echo %errorlevel%
-536870884

I couldn't find anything on this topic in the SecureFX included help files and I searched the FAQ here for errorlevel but nothing came up.

?
Thanks for any advise or suggestions.
Dusty
Reply With Quote
  #2  
Old 03-23-2012, 12:26 PM
miked's Avatar
miked miked is offline
Registered User
 
Join Date: Feb 2004
Posts: 2,040
I can understand why you would expect to see a non-zero result. "Attempted to transfer 0 files" also seems telling, thinking about why it might not be considered an error. I believe I can duplicate the same results as you, but it would be good to see a log file just in case there's something else happening that our developers should be aware of.

Can you send the complete SFXCL log output to support@vandyke.com with subject Forum 10368 Attn Mike?
__________________
Mike
VanDyke Software
Technical Support
[http://www.vandyke.com/support]
Reply With Quote
  #3  
Old 03-23-2012, 04:50 PM
miked's Avatar
miked miked is offline
Registered User
 
Join Date: Feb 2004
Posts: 2,040
You're correct. SFXCL should return non-zero if wild-cards don't match entries on the remote. Version 6.7 does not do this correctly. A fix is available in a SecureFX 6.8, currently available as a pre-release version. If you would like to try the pre-release version, please let us know and refer to forum thread 10368.
__________________
Mike
VanDyke Software
Technical Support
[http://www.vandyke.com/support]

Last edited by miked; 03-26-2012 at 10:36 AM.
Reply With Quote
  #4  
Old 03-26-2012, 10:31 AM
dthompto dthompto is offline
Registered User
 
Join Date: Jan 2009
Posts: 3
forum thread 10368

Thank you. Yes I would like to try the new version.
Reply With Quote
  #5  
Old 03-26-2012, 10:41 AM
miked's Avatar
miked miked is offline
Registered User
 
Join Date: Feb 2004
Posts: 2,040
Oops! I'm sorry. I forgot to make please let us know a link. We need to have your e-mail so that we can upload the installer for you. We wouldn't want you to post your e-mail address to a public forum (could result in spam) so anyone interested should contact us through our support form and refer to forum thread 10368.
__________________
Mike
VanDyke Software
Technical Support
[http://www.vandyke.com/support]
Reply With Quote
Reply

Tags
code, errorlevel, return


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 09:29 PM.


copyright 1995-2014 VanDyke Software, Inc.