1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00
Commit Graph

20 Commits

Author SHA1 Message Date
Daniel Stenberg
0f55269aff
copyright: update mismatched copyright years 2020-06-22 11:55:34 +02:00
Radoslav Georgiev
abfd154efd
examples/http2-down/upload: add error checks
If `index.html` does not exist in the directory from which the example
is invoked, the fopen(upload, "rb") invocation in `setup` would fail,
returning NULL.  This value is subsequently passed as the FILE* argument
of the `fread` invocation in the `read_callback` function, which is the
actual cause of the crash (apparently `fread` assumes that argument to
be non-null).

In addition, mitigate some possible crashes of similar origin.

Closes #5463
2020-06-02 00:14:08 +02:00
Marcel Raad
918987a844
http2-download: fix format specifier
Closes https://github.com/curl/curl/pull/3919
2019-05-22 10:06:17 +02:00
Daniel Stenberg
b2e5af4aec
examples/http2-download: cleaned up
To avoid scan-build warnings and global variables.
2019-02-14 23:30:43 +01:00
Kamil Dudka
1d173f3413 docs/examples: do not wait when no transfers are running
Closes #2948
2018-09-10 12:23:23 +02:00
Marcel Raad
5bd8c389a3
examples: fix -Wformat warnings
When size_t is not a typedef for unsigned long (as usually the case on
Windows), GCC emits -Wformat warnings when using lu and lx format
specifiers with size_t. Silence them with explicit casts to
unsigned long.

Closes https://github.com/curl/curl/pull/2721
2018-07-09 18:08:27 +02:00
Rikard Falkeborn
13505dcb55
examples: Fix format specifiers
Closes #2561
2018-05-14 09:43:15 +02:00
Daniel Stenberg
e5743f08e7
code style: use spaces around pluses 2017-09-11 09:29:50 +02:00
Daniel Stenberg
6b84438d9a
code style: use spaces around equals signs 2017-09-11 09:29:50 +02:00
Marcel Raad
b4d87f54d6
examples: fix Wimplicit-fallthrough warnings
This is contained in -Wextra with GCC 7.
2017-05-24 11:56:38 +02:00
Marcel Raad
c23177d5e9
examples: declare TU-local variables static
This fixes missing-variable-declarations warnings when building with
clang.
2017-04-30 23:29:31 +02:00
Daniel Stenberg
26baf39f3d examples: comment typos in http2 examples 2017-03-21 12:55:46 +01:00
Daniel Stenberg
b228d2952b checksrc: stricter no-space-before-paren enforcement
In order to make the code style more uniform everywhere
2016-12-13 23:39:11 +01:00
Daniel Stenberg
3a6563d668 examples: adhere to curl code style
All plain C examples now (mostly) adhere to the curl code style. While
they are only examples, they had diverted so much and contained all
sorts of different mixed code styles by now. Having them use a unified
style helps users and readability. Also, as they get copy-and-pasted
widely by users, making sure they're clean and nice is a good idea.

573 checksrc warnings were addressed.
2016-02-11 09:44:45 +01:00
Daniel Stenberg
4af40b3646 URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
Steve Holme
c90e348579 examples: Fixed compilation warnings
pop3-multi.c:96:5: warning: implicit declaration of function 'memset'
imap-multi.c:96:5: warning: implicit declaration of function 'memset'
http2-download.c:226:5: warning: implicit declaration of function 'memset'
http2-upload.c:290:5: warning: implicit declaration of function 'memset'
http2-upload.c:290:5: warning: implicit declaration of function 'memset'
2015-11-21 01:47:02 +00:00
Daniel Stenberg
c00b18d540 examples: provide <DESC> sections 2015-07-01 11:43:12 +02:00
Daniel Stenberg
41db5aed7a http2-download: check for CURLPIPE_MULTIPLEX properly
Bug: http://curl.haxx.se/mail/lib-2015-06/0001.html
Reported-by: Rafayel Mkrtchyan
2015-06-01 08:45:30 +02:00
Daniel Stenberg
d1b1d782f5 http2 examples: clean up some comments 2015-05-28 16:04:00 +02:00
Daniel Stenberg
e57f08863a examples: added two programs doing multiplexed HTTP/2 2015-05-28 15:58:34 +02:00