aboutsummaryrefslogtreecommitdiff
path: root/lib/file.c
AgeCommit message (Collapse)Author
2007-11-15Rearranged code and changed Curl_readwrite_init() and Curl_pre_readwrite() intoDaniel Stenberg
do_init() and do_complete() which now are called first and last in the DO function. It simplified the flow in multi.c and the functions got more sensible names!
2007-11-07if () => if()Daniel Stenberg
while () => while() and some other minor re-indentings
2007-10-30Fixed an OOM problem with file: URLsDan Fandrich
Moved Curl_file_connect into the protocol handler struct.
2007-10-23File is not a protocol that can deal with "persistancy"Yang Tse
2007-10-22Michal Marek forwarded the bug reportDaniel Stenberg
https://bugzilla.novell.com/show_bug.cgi?id=332917 about a HTTP redirect to FTP that caused memory havoc. His work together with my efforts created two fixes: #1 - FTP::file was moved to struct ftp_conn, because is has to be dealt with at connection cleanup, at which time the struct HandleData could be used by another connection. Also, the unused char *urlpath member is removed from struct FTP. #2 - provide a Curl_reset_reqproto() function that frees data->reqdata.proto.* on connection setup if needed (that is if the SessionHandle was used by a different connection).
2007-10-17We use this ZERO_NULL to avoid picky compiler warnings,Yang Tse
when assigning a NULL pointer to a function pointer var.
2007-10-13Made a few more functions static with the protocol handler table in place.Dan Fandrich
2007-10-12Added per-protocol callback static tables, replacing callback ptr storagePatrick Monnerat
in the connectdata structure by a single handler table ptr.
2007-09-27Enabled a few more gcc warnings with --enable-debug. Renamed a fewDan Fandrich
variables to avoid shadowing global declarations.
2007-08-29Added lots of constsDan Fandrich
2007-08-22Bug report #1779751 (http://curl.haxx.se/bug/view.cgi?id=1779751) pointedDaniel Stenberg
out that doing first a file:// upload and then an FTP upload crashed libcurl or at best caused furious valgrind complaints. Fixed now by making sure we free and clear the file-specific struct properly when done with it.
2007-07-23Implemented only the parts of Patrick Monnerat's OS/400 patch that renamedDan Fandrich
some few internal identifiers to avoid conflicts, which could be useful on other platforms.
2007-06-28Using fdopen() is a more correct way to implement the CURLOPT_NEW_FILE_PREMSJames Housley
file.c, but the debug interface was missing. This adds the routines needed to make the memory debuging work for fdopen().
2007-06-27Add two new options for the SFTP/SCP/FILE protocols: CURLOPT_NEW_FILE_PERMSJames Housley
and CURLOPT_NEW_DIRECTORY_PERMS. These control the premissions for files and directories created on the remote server. CURLOPT_NEW_FILE_PERMS defaults to 0644 and CURLOPT_NEW_DIRECTORY_PERMS defaults to 0755
2007-06-07Fixed a compiler warning on uClibc.Dan Fandrich
2007-05-31Feng Tu made (lib)curl support "upload" resuming work for file:// URLs.Daniel Stenberg
2007-02-26Removed inclusion of <sys/types.h> and <sys/stat.h> in .c-filesGisle Vanem
since they're already included through "setup.h".
2007-01-16- Armel Asselin improved libcurl to behave a lot better when an easy handleDaniel Stenberg
doing an FTP transfer is removed from a multi handle before completion. The fix also fixed the "alive counter" to be correct on "premature removal" for all protocols.
2006-10-18use the return code from lseek() to detect problems and bail out if soDaniel Stenberg
2006-10-11Remove redundant __CYGWIN__ symbol checkYang Tse
2006-09-07Major overhaul introducing http pipelining support and shared connectionDaniel Stenberg
cache within the multi handle.
2006-09-03Simplified #ifdef on WIN32; the statementGisle Vanem
" !defined(__GNUC__) || defined(__MINGW32__)" implies CygWin.
2006-08-30Removed "#ifndef__WATCOMC__". Use "#ifdef HAVE_SYS_TIME_H" instead.Gisle Vanem
2006-08-29Watcom lacks <sys/time.h>.Gisle Vanem
2006-08-19Based on a patch by Armel Asselin, the FTP code no longer re-issues the TYPEDaniel Stenberg
command on subsequent requests on a re-used connection unless it has to.
2006-05-04Roland Blom filed bug report #1481217Daniel Stenberg
(http://curl.haxx.se/bug/view.cgi?id=1481217), with follow-ups by Michele Bini and David Byron. libcurl previously wrongly used GetLastError() on windows to get error details after socket-related function calls, when it really should use WSAGetLastError() instead. When changing to this, the former function Curl_ourerrno() is now instead called Curl_sockerrno() as it is necessary to only use it to get errno from socket-related functions as otherwise it won't work as intended on Windows.
2006-04-07First commit of David McCreedy's EBCDIC and TPF changes.Daniel Stenberg
2005-12-30fix questionable compare compiler error (unsigned can't be < 0)Marty Kuhrt
2005-12-30putting back into distMarty Kuhrt
2005-12-01Jamie Newton pointed out that libcurl's file:// code would close() a zeroDaniel Stenberg
file descriptor if given a non-existing file.
2005-02-11Removed all uses of strftime() since it uses the localised version of theDaniel Stenberg
week day names and month names and servers don't like that.
2005-02-09FTP code turned into state machine. Not completely yet, but a good start.Daniel Stenberg
The tag 'before_ftp_statemachine' was set just before this commit in case of future need.
2004-12-16moved the lseek() and stat() magic defines to setup.h and now take advantageDaniel Stenberg
of struct_stat in formdata.c as well, to support formpost uploads of large files on Windows too
2004-12-13Gisle's fix for resuming large file:// files on windows - slightly editedDaniel Stenberg
by me.
2004-12-11provide an error string when resuming fails - and use the proper error code,Daniel Stenberg
not the former one
2004-11-09Handle drive-letter on MS-DOS.Gisle Vanem
2004-11-02Paul Nolan fix to make libcurl build nicely on Windows CEDaniel Stenberg
2004-10-06removed tabs and trailing whitespace from sourceDaniel Stenberg
2004-08-17Kjetil Jacobsen reported an open file leak in file:// transfers of emptyDaniel Stenberg
files.
2004-07-06Andres Garcia pointed out that we searched for a slash badly since it isDaniel Stenberg
converted and thus we must search for backslash on windows
2004-06-24fix warningDaniel Stenberg
2004-06-24Replaced all uses of sprintf() with the safer snprintf(). It is just aDaniel Stenberg
precaution to prevent mistakes to lead to buffer overflows.
2004-06-21The read callback can now return CURL_READFUNC_ABORT to stop a transfer.Daniel Stenberg
2004-06-10Steven Bazyl and Seshubabu Pasam pointed out a bug on win32 when freeing theDaniel Stenberg
path after a transfer.
2004-05-25initial support for "uploading" to file:// URLsDaniel Stenberg
2004-05-13better bailing out in case of no memoryDaniel Stenberg
2004-05-11curl_global_init_mem() allows the memory functions to be replaced.Daniel Stenberg
memory.h is included everywhere for this.
2004-04-26added commentsDaniel Stenberg
2004-04-06New authentication code added, particularly noticable when doing POST or PUTDaniel Stenberg
with Digest or NTLM. libcurl will now use HEAD to negotiate the authentication and when done perform the requested POST.
2004-03-10Use more curl_off_t variables when doing the progress meter calculations andDaniel Stenberg
argument passing and try to convert to double only when providing data to the external world.