summaryrefslogtreecommitdiffstats
path: root/libftp/ftplib.c
diff options
context:
space:
mode:
Diffstat (limited to 'libftp/ftplib.c')
-rw-r--r--libftp/ftplib.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/libftp/ftplib.c b/libftp/ftplib.c
index 9089a5b3..d8c25f58 100644
--- a/libftp/ftplib.c
+++ b/libftp/ftplib.c
@@ -1104,7 +1104,7 @@ static int FtpXfer(const char *localfile, const char *path,
if (localfile != NULL)
{
- char ac[4] = "w";
+ char ac[4] = "a";
if (typ == FTPLIB_FILE_WRITE)
ac[0] = 'r';
if (mode == FTPLIB_IMAGE)
@@ -1200,6 +1200,22 @@ GLOBALDEF int FtpSize(const char *path, int *size, char mode, netbuf *nControl)
}
/*
+ * FtpRestart - issue a REST command
+ *
+ * return 1 if successful, 0 otherwise
+ */
+GLOBALDEF int FtpRestart(int offset, netbuf *nControl)
+{
+ char cmd[256];
+ int rv=1;
+
+ sprintf(cmd,"REST %d",offset);
+ if (!FtpSendCmd(cmd,'3',nControl))
+ rv = 0;
+ return rv;
+}
+
+/*
* FtpModDate - determine the modification date of a remote file
*
* return 1 if successful, 0 otherwise