X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/0bd57c0f66354345eac1d1654a56860919254b4c..8412ec80fffa6d4e3422a7240409a9d775b29c44:/psftp.c diff --git a/psftp.c b/psftp.c index 63446d4d..e0fbee8d 100644 --- a/psftp.c +++ b/psftp.c @@ -16,6 +16,8 @@ #include "sftp.h" #include "int64.h" +const char *const appname = "PSFTP"; + /* * Since SFTP is a request-response oriented protocol, it requires * no buffer management: when we send data, we stop and wait for an @@ -2240,6 +2242,11 @@ struct sftp_command *sftp_getcmd(FILE *fp, int mode, int modeflags) cmd->words = sresize(cmd->words, cmd->wordssize, char *); cmd->words[0] = dupstr("!"); cmd->words[1] = dupstr(p+1); + } else if (*p == '#') { + /* + * Special case: comment. Entire line is ignored. + */ + cmd->nwords = cmd->wordssize = 0; } else { /*