[sword-svn] r3816 - trunk/src/mgr

scribe at crosswire.org scribe at crosswire.org
Mon Oct 19 06:13:59 EDT 2020


Author: scribe
Date: 2020-10-19 06:13:59 -0400 (Mon, 19 Oct 2020)
New Revision: 3816

Modified:
   trunk/src/mgr/ftplibftpt.cpp
Log:
Followed Jaaks recommendation and passed a pointer the int instead of just the int


Modified: trunk/src/mgr/ftplibftpt.cpp
===================================================================
--- trunk/src/mgr/ftplibftpt.cpp	2020-10-18 22:20:30 UTC (rev 3815)
+++ trunk/src/mgr/ftplibftpt.cpp	2020-10-19 10:13:59 UTC (rev 3816)
@@ -49,7 +49,7 @@
 	}
 
 	static int my_filewriter(netbuf *nControl, void *buffer, size_t size, void *fd) {
-		int output = (int)(size_t)fd;
+		int output = *((int *)fd);
 		FileMgr::write(output, buffer, size);
 		return (int)size;
 	}
@@ -161,7 +161,7 @@
 	else {
 		fd = FileMgr::createPathAndFile(outFile);
 		FtpOptions(FTPLIB_CALLBACK_WRITER, (long)&my_filewriter, ftpConnection);
-		FtpOptions(FTPLIB_CALLBACK_WRITERARG, (long)fd, ftpConnection);
+		FtpOptions(FTPLIB_CALLBACK_WRITERARG, (long)&fd, ftpConnection);
 	}
 
 	FtpOptions(FTPLIB_CALLBACK, (long)&my_fprogress, ftpConnection);



More information about the sword-cvs mailing list