Commit Graph

1383 Commits

Author SHA1 Message Date
Daniel Stenberg b9660dc4b2 FindWin32CACert: return OK even if CA cert isn't found
Bug: http://curl.haxx.se/mail/lib-2011-11/0180.html
Reported by: Mark Brand
2011-11-17 18:05:27 +01:00
Daniel Stenberg 10120e6ab5 progress_cb: avoid buffer overflow
The progress bar output function would blindly use the terminal width
without bounds checking. When using a very wide terminal that caused a
buffer overflow and segfault.

We now limit the max bar with to 255 columns, and I simplified the code
to avoid an extra snprintf and buffer.

Bug: http://curl.haxx.se/bug/view.cgi?id=3435710
Reported by: Alexey Zakhlestin
2011-11-11 19:57:49 +01:00
Yang Tse 5b57c54416 tool_cb_wrt.c: disambiguate warning message 2011-11-03 23:26:38 +01:00
Yang Tse 7fe9a50ab5 tool_cfgable.c: pending check done 2011-11-03 23:21:01 +01:00
Yang Tse 9cfc0c73a7 tool_cb_see.h: fix compiler warning 2011-11-01 12:53:23 +01:00
Yang Tse 49e3b2e03a setup.h: fix compiler warning 2011-10-31 22:42:43 +01:00
Daniel Stenberg 515f11e79b large headers: have curl accept >16K headers
As commit 5850cc4808 clarifies, libcurl can deliver header lines that
are longer than CURL_MAX_WRITE_SIZE, only body data is limited to that
size. The curl tool has check (when built debug-enabled) that made the
wrong checks and this new test 1205 verifies that larger headers work.
2011-10-24 17:28:41 +02:00
Yang Tse cc76bbe79b tool_operate.c: OOM handling fix
Move curl_easy_perform source code geneartion out of curl_easy_perform's loop
for proper OOM handling and source code geneartion.
2011-10-22 14:49:02 +02:00
Daniel Stenberg b229c8ca8b --show-error: position indepdenent
Previously we required that -S/--show-error was used _after_
-s/--silent. This was slightly confusing since we strive to make
arguments as position independent as possible.

Now, you can use them in any order and the result should still be the
same.

Bug: http://curl.haxx.se/bug/view.cgi?id=3424286
Reported by: Andreas Olsson
2011-10-16 23:39:59 +02:00
Yang Tse 17f48fe879 libcurl: some OOM handling fixes 2011-10-07 20:50:57 +02:00
Yang Tse f7bfdbabf2 curl tool: reviewed code moved to tool_*.[ch] files 2011-10-06 17:39:00 +02:00
Yang Tse 4a57bf6d10 curl tool: fix compiler warning 2011-10-05 22:27:29 +02:00
Yang Tse 7296b2aa25 curl tool: OOM handling fixes 2011-10-05 22:01:42 +02:00
Yang Tse 6c849321d7 curl tool: reviewed code moved to tool_*.[ch] files 2011-10-05 20:16:16 +02:00
Yang Tse 0f19e0145a curl tool: OOM handling fixes 2011-10-05 19:33:46 +02:00
Yang Tse ec73fd89ed curl tool: OOM handling fixes 2011-10-05 16:41:04 +02:00
Yang Tse 5bf0d74120 curl tool: OOM handling fixes 2011-10-05 15:06:26 +02:00
Yang Tse fd87d9d2b9 curl tool: header inclusion adjustment 2011-10-05 12:40:30 +02:00
Yang Tse 0572ad6d01 curl tool: symbol check adjustment 2011-10-05 02:58:18 +02:00
Yang Tse aa7d5b946a curl tool: header inclusion adjustment 2011-10-05 01:19:58 +02:00
Yang Tse 49b79b7631 curl tool: code moved to tool_*.[ch] files 2011-10-05 00:03:58 +02:00
Yang Tse 0435800f65 curl tool: reviewed code moved to tool_*.[ch] files 2011-10-03 23:00:47 +02:00
Yang Tse 7be872c389 curl tool: fix some more OOM handling 2011-09-30 21:10:58 +02:00
Yang Tse ff5ba6e43d curl tool: adjust header callback single call write limit warning
Maximum amount of data a header callback is supposed to get in
a single call from libcurl is limited by the lowest value of
CURL_MAX_WRITE_SIZE and CURL_MAX_HTTP_HEADER.
2011-09-28 19:04:38 +02:00
Guenter Knauf b4fccc1d8e Added SPNEGO to NetWare build. 2011-09-27 16:02:07 +02:00
Yang Tse e2be8ceed9 curl tool: fix a compiler warning 2011-09-26 21:19:41 +02:00
Yang Tse d439830621 curl tool: fix some OOM handling - f4853db5 follow-up 2011-09-26 13:44:24 +02:00
Yang Tse f4853db5e6 curl tool: fix some OOM handling 2011-09-26 13:07:34 +02:00
Yang Tse d9f686db88 remove short-lived CURL_WRITEFUNC_OUT_OF_MEMORY 2011-09-26 13:05:42 +02:00
Yang Tse 119f43360b allow write callbacks to indicate OOM to libcurl
Allow (*curl_write_callback) write callbacks to return
CURL_WRITEFUNC_OUT_OF_MEMORY to properly indicate libcurl of OOM conditions
inside the callback itself.
2011-09-25 19:05:46 +02:00
Guenter Knauf 230459dd00 NetWare makefile tweaks to select different builds. 2011-09-25 16:29:08 +02:00
Daniel Stenberg 745014b726 POST: always set postfieldsize
When we use binary posts and regular ones intermixed on a single command
line, we cannot do strlen() etc on the data to figure out the length
(when inserting '&' and more). We must therefore keep track of the post
data length. Then we also end up setting the libcurl option with the
known size, so that we don't risk that libcurl will do strlen() on the
data.

This has the minor side-effect that --libcurl source codes now always
will use CURLOPT_POSTFIELDSIZE but I don't consider that terribly
damaging.

Bug: http://curl.haxx.se/bug/view.cgi?id=3413181
Reported by: Taneli Vähäkangas
2011-09-25 00:02:58 +02:00
Yang Tse b3ea4881a8 curl tool: fix a compiler warning 2011-09-24 18:33:59 +02:00
Yang Tse c6702c7d3f curl tool: reviewed code moved to tool_*.[ch] files 2011-09-24 17:40:46 +02:00
Yang Tse 081e289315 curl tool: fix some OOM handling issues 2011-09-24 05:33:41 +02:00
Yang Tse fa775b56de curl tool: fix some OOM handling issues 2011-09-22 21:21:21 +02:00
Yang Tse fb3845a438 curl tool: reviewed code moved to tool_*.[ch] files
my_setopt and my_setopt_str no longer ignores curl_easy_setopt result.

Fixed some OOM handling issues.
2011-09-22 21:21:20 +02:00
Yang Tse 28526ed6e0 curl tool: make my_setopt ignore curl_easy_setopt result again.
Related code not ready yet for this kind of checks.
2011-09-21 04:30:08 +02:00
Guenter Knauf e4172d934d Changed suffix rules to pattern rules.
Suffix rules cannot have any prerequisites of their own.
2011-09-21 03:25:19 +02:00
Guenter Knauf a6b69b64ad Some more MinGW build tweaks.
Added envvars to specify OpenSSL include, libpath and lib.
Added rule to create curlbuild.h from curlbuild.h.dist.
2011-09-21 02:06:05 +02:00
Yang Tse 9ecf53e154 curl tool: reviewed code moved to tool_*.[ch] files
my_setopt and my_setopt_str no longer ignores curl_easy_setopt result.

Fixed some OOM handling issues.
2011-09-21 01:54:14 +02:00
Yang Tse 84221006c9 curl tool: reviewed code moved to tool_*.[ch] files
Overhauled FindWin32CACert()
2011-09-20 15:59:19 +02:00
Guenter Knauf a6c168b893 A bunch of MinGW build tweaks.
All paths to dependencies now quoted; synced examples makefile.
2011-09-20 15:05:28 +02:00
Guenter Knauf 98a61d8e2e Added _WIN32_WINNT define for IPv6 builds. 2011-09-20 11:59:49 +02:00
Yang Tse 49c35a7f9f curl tool: truly fix compiler warning 2011-09-19 20:27:25 +02:00
Yang Tse 57119495da curl tool: fix compiler warning 2011-09-19 19:45:58 +02:00
Yang Tse fdecb56cbf curl tool: reviewed code moved to tool_*.[ch] files 2011-09-19 18:18:17 +02:00
Yang Tse 260b0f4d0c curl tool: create tool_myfunc.[ch] which later on will hold my_* functions
Additionally function my_useragent() now provides default User-Agent string
2011-09-18 01:59:25 +02:00
Yang Tse f50d4647d0 curl tool: reorder free_config_fields() field handling
Reorder handling of fields to match same order as the one given by current
definition order of 'Configurable' struct fields. Fields currently not handled
marked for further inspection.
2011-09-18 01:59:21 +02:00
Guenter Knauf 805b4740c7 Fixed MinGW WinIDN lib dependency. 2011-09-17 17:59:35 +02:00