mirror of
https://github.com/curl/curl.git
synced 2026-04-15 01:01:41 +03:00
code: language cleanup in comments
Based on the standards and guidelines we use for our documentation. - expand contractions (they're => they are etc) - host name = > hostname - file name => filename - user name = username - man page => manpage - run-time => runtime - set-up => setup - back-end => backend - a HTTP => an HTTP - Two spaces after a period => one space after period Closes #14073
This commit is contained in:
parent
9b683577e1
commit
c074ba64a8
213 changed files with 1719 additions and 1715 deletions
|
|
@ -8,7 +8,7 @@ SPDX-License-Identifier: curl
|
|||
|
||||
Public include files for libcurl, external users.
|
||||
|
||||
They're all placed in the curl subdirectory here for better fit in any kind of
|
||||
They are all placed in the curl subdirectory here for better fit in any kind of
|
||||
environment. You must include files from here using...
|
||||
|
||||
#include <curl/curl.h>
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@
|
|||
#endif
|
||||
|
||||
#include "curlver.h" /* libcurl version defines */
|
||||
#include "system.h" /* determine things run-time */
|
||||
#include "system.h" /* determine things runtime */
|
||||
|
||||
#include <stdio.h>
|
||||
#include <limits.h>
|
||||
|
|
@ -77,7 +77,7 @@
|
|||
#if !(defined(_WINSOCKAPI_) || defined(_WINSOCK_H) || \
|
||||
defined(__LWIP_OPT_H__) || defined(LWIP_HDR_OPT_H))
|
||||
/* The check above prevents the winsock2 inclusion if winsock.h already was
|
||||
included, since they can't co-exist without problems */
|
||||
included, since they cannot co-exist without problems */
|
||||
#include <winsock2.h>
|
||||
#include <ws2tcpip.h>
|
||||
#endif
|
||||
|
|
@ -197,9 +197,9 @@ struct curl_httppost {
|
|||
files */
|
||||
long flags; /* as defined below */
|
||||
|
||||
/* specified content is a file name */
|
||||
/* specified content is a filename */
|
||||
#define CURL_HTTPPOST_FILENAME (1<<0)
|
||||
/* specified content is a file name */
|
||||
/* specified content is a filename */
|
||||
#define CURL_HTTPPOST_READFILE (1<<1)
|
||||
/* name is only stored pointer do not free in formfree */
|
||||
#define CURL_HTTPPOST_PTRNAME (1<<2)
|
||||
|
|
@ -215,8 +215,8 @@ struct curl_httppost {
|
|||
/* use size in 'contentlen', added in 7.46.0 */
|
||||
#define CURL_HTTPPOST_LARGE (1<<7)
|
||||
|
||||
char *showfilename; /* The file name to show. If not set, the
|
||||
actual file name will be used (if this
|
||||
char *showfilename; /* The filename to show. If not set, the
|
||||
actual filename will be used (if this
|
||||
is a file part) */
|
||||
void *userp; /* custom pointer used for
|
||||
HTTPPOST_CALLBACK posts */
|
||||
|
|
@ -358,13 +358,13 @@ typedef long (*curl_chunk_bgn_callback)(const void *transfer_info,
|
|||
download of an individual chunk finished.
|
||||
Note! After this callback was set then it have to be called FOR ALL chunks.
|
||||
Even if downloading of this chunk was skipped in CHUNK_BGN_FUNC.
|
||||
This is the reason why we don't need "transfer_info" parameter in this
|
||||
This is the reason why we do not need "transfer_info" parameter in this
|
||||
callback and we are not interested in "remains" parameter too. */
|
||||
typedef long (*curl_chunk_end_callback)(void *ptr);
|
||||
|
||||
/* return codes for FNMATCHFUNCTION */
|
||||
#define CURL_FNMATCHFUNC_MATCH 0 /* string corresponds to the pattern */
|
||||
#define CURL_FNMATCHFUNC_NOMATCH 1 /* pattern doesn't match the string */
|
||||
#define CURL_FNMATCHFUNC_NOMATCH 1 /* pattern does not match the string */
|
||||
#define CURL_FNMATCHFUNC_FAIL 2 /* an error occurred */
|
||||
|
||||
/* callback type for wildcard downloading pattern matching. If the
|
||||
|
|
@ -376,7 +376,7 @@ typedef int (*curl_fnmatch_callback)(void *ptr,
|
|||
/* These are the return codes for the seek callbacks */
|
||||
#define CURL_SEEKFUNC_OK 0
|
||||
#define CURL_SEEKFUNC_FAIL 1 /* fail the entire transfer */
|
||||
#define CURL_SEEKFUNC_CANTSEEK 2 /* tell libcurl seeking can't be done, so
|
||||
#define CURL_SEEKFUNC_CANTSEEK 2 /* tell libcurl seeking cannot be done, so
|
||||
libcurl might try other means instead */
|
||||
typedef int (*curl_seek_callback)(void *instream,
|
||||
curl_off_t offset,
|
||||
|
|
@ -459,7 +459,7 @@ typedef curlioerr (*curl_ioctl_callback)(CURL *handle,
|
|||
#ifndef CURL_DID_MEMORY_FUNC_TYPEDEFS
|
||||
/*
|
||||
* The following typedef's are signatures of malloc, free, realloc, strdup and
|
||||
* calloc respectively. Function pointers of these types can be passed to the
|
||||
* calloc respectively. Function pointers of these types can be passed to the
|
||||
* curl_global_init_mem() function to set user defined memory management
|
||||
* callback routines.
|
||||
*/
|
||||
|
|
@ -547,17 +547,17 @@ typedef enum {
|
|||
CURLE_WRITE_ERROR, /* 23 */
|
||||
CURLE_OBSOLETE24, /* 24 - NOT USED */
|
||||
CURLE_UPLOAD_FAILED, /* 25 - failed upload "command" */
|
||||
CURLE_READ_ERROR, /* 26 - couldn't open/read from file */
|
||||
CURLE_READ_ERROR, /* 26 - could not open/read from file */
|
||||
CURLE_OUT_OF_MEMORY, /* 27 */
|
||||
CURLE_OPERATION_TIMEDOUT, /* 28 - the timeout time was reached */
|
||||
CURLE_OBSOLETE29, /* 29 - NOT USED */
|
||||
CURLE_FTP_PORT_FAILED, /* 30 - FTP PORT operation failed */
|
||||
CURLE_FTP_COULDNT_USE_REST, /* 31 - the REST command failed */
|
||||
CURLE_OBSOLETE32, /* 32 - NOT USED */
|
||||
CURLE_RANGE_ERROR, /* 33 - RANGE "command" didn't work */
|
||||
CURLE_RANGE_ERROR, /* 33 - RANGE "command" did not work */
|
||||
CURLE_HTTP_POST_ERROR, /* 34 */
|
||||
CURLE_SSL_CONNECT_ERROR, /* 35 - wrong when connecting with SSL */
|
||||
CURLE_BAD_DOWNLOAD_RESUME, /* 36 - couldn't resume download */
|
||||
CURLE_BAD_DOWNLOAD_RESUME, /* 36 - could not resume download */
|
||||
CURLE_FILE_COULDNT_READ_FILE, /* 37 */
|
||||
CURLE_LDAP_CANNOT_BIND, /* 38 */
|
||||
CURLE_LDAP_SEARCH_FAILED, /* 39 */
|
||||
|
|
@ -581,9 +581,9 @@ typedef enum {
|
|||
CURLE_RECV_ERROR, /* 56 - failure in receiving network data */
|
||||
CURLE_OBSOLETE57, /* 57 - NOT IN USE */
|
||||
CURLE_SSL_CERTPROBLEM, /* 58 - problem with the local certificate */
|
||||
CURLE_SSL_CIPHER, /* 59 - couldn't use specified cipher */
|
||||
CURLE_SSL_CIPHER, /* 59 - could not use specified cipher */
|
||||
CURLE_PEER_FAILED_VERIFICATION, /* 60 - peer's certificate or fingerprint
|
||||
wasn't verified fine */
|
||||
was not verified fine */
|
||||
CURLE_BAD_CONTENT_ENCODING, /* 61 - Unrecognized/bad encoding */
|
||||
CURLE_OBSOLETE62, /* 62 - NOT IN USE since 7.82.0 */
|
||||
CURLE_FILESIZE_EXCEEDED, /* 63 - Maximum file size exceeded */
|
||||
|
|
@ -612,7 +612,7 @@ typedef enum {
|
|||
CURLE_SSL_SHUTDOWN_FAILED, /* 80 - Failed to shut down the SSL
|
||||
connection */
|
||||
CURLE_AGAIN, /* 81 - socket is not ready for send/recv,
|
||||
wait till it's ready and try again (Added
|
||||
wait till it is ready and try again (Added
|
||||
in 7.18.2) */
|
||||
CURLE_SSL_CRL_BADFILE, /* 82 - could not load CRL file, missing or
|
||||
wrong format (Added in 7.19.0) */
|
||||
|
|
@ -788,7 +788,7 @@ typedef enum {
|
|||
CURLPROXY_SOCKS5 = 5, /* added in 7.10 */
|
||||
CURLPROXY_SOCKS4A = 6, /* added in 7.18.0 */
|
||||
CURLPROXY_SOCKS5_HOSTNAME = 7 /* Use the SOCKS5 protocol but pass along the
|
||||
host name rather than the IP address. added
|
||||
hostname rather than the IP address. added
|
||||
in 7.18.0 */
|
||||
} curl_proxytype; /* this enum was added in 7.10 */
|
||||
|
||||
|
|
@ -868,7 +868,7 @@ enum curl_khstat {
|
|||
CURLKHSTAT_FINE_ADD_TO_FILE,
|
||||
CURLKHSTAT_FINE,
|
||||
CURLKHSTAT_REJECT, /* reject the connection, return an error */
|
||||
CURLKHSTAT_DEFER, /* do not accept it, but we can't answer right now.
|
||||
CURLKHSTAT_DEFER, /* do not accept it, but we cannot answer right now.
|
||||
Causes a CURLE_PEER_FAILED_VERIFICATION error but the
|
||||
connection will be left intact etc */
|
||||
CURLKHSTAT_FINE_REPLACE, /* accept and replace the wrong key */
|
||||
|
|
@ -1088,7 +1088,7 @@ typedef CURLSTScode (*curl_hstswrite_callback)(CURL *easy,
|
|||
#define CURLOPT(na,t,nu) na = t + nu
|
||||
#define CURLOPTDEPRECATED(na,t,nu,v,m) na CURL_DEPRECATED(v,m) = t + nu
|
||||
|
||||
/* CURLOPT aliases that make no run-time difference */
|
||||
/* CURLOPT aliases that make no runtime difference */
|
||||
|
||||
/* 'char *' argument to a string with a trailing zero */
|
||||
#define CURLOPTTYPE_STRINGPOINT CURLOPTTYPE_OBJECTPOINT
|
||||
|
|
@ -1155,7 +1155,7 @@ typedef enum {
|
|||
*
|
||||
* For large file support, there is also a _LARGE version of the key
|
||||
* which takes an off_t type, allowing platforms with larger off_t
|
||||
* sizes to handle larger files. See below for INFILESIZE_LARGE.
|
||||
* sizes to handle larger files. See below for INFILESIZE_LARGE.
|
||||
*/
|
||||
CURLOPT(CURLOPT_INFILESIZE, CURLOPTTYPE_LONG, 14),
|
||||
|
||||
|
|
@ -1188,7 +1188,7 @@ typedef enum {
|
|||
*
|
||||
* Note there is also a _LARGE version of this key which uses
|
||||
* off_t types, allowing for large file offsets on platforms which
|
||||
* use larger-than-32-bit off_t's. Look below for RESUME_FROM_LARGE.
|
||||
* use larger-than-32-bit off_t's. Look below for RESUME_FROM_LARGE.
|
||||
*/
|
||||
CURLOPT(CURLOPT_RESUME_FROM, CURLOPTTYPE_LONG, 21),
|
||||
|
||||
|
|
@ -1324,9 +1324,9 @@ typedef enum {
|
|||
/* Set the interface string to use as outgoing network interface */
|
||||
CURLOPT(CURLOPT_INTERFACE, CURLOPTTYPE_STRINGPOINT, 62),
|
||||
|
||||
/* Set the krb4/5 security level, this also enables krb4/5 awareness. This
|
||||
* is a string, 'clear', 'safe', 'confidential' or 'private'. If the string
|
||||
* is set but doesn't match one of these, 'private' will be used. */
|
||||
/* Set the krb4/5 security level, this also enables krb4/5 awareness. This
|
||||
* is a string, 'clear', 'safe', 'confidential' or 'private'. If the string
|
||||
* is set but does not match one of these, 'private' will be used. */
|
||||
CURLOPT(CURLOPT_KRBLEVEL, CURLOPTTYPE_STRINGPOINT, 63),
|
||||
|
||||
/* Set if we should verify the peer in ssl handshake, set 1 to verify. */
|
||||
|
|
@ -1358,16 +1358,16 @@ typedef enum {
|
|||
/* 73 = OBSOLETE */
|
||||
|
||||
/* Set to explicitly use a new connection for the upcoming transfer.
|
||||
Do not use this unless you're absolutely sure of this, as it makes the
|
||||
Do not use this unless you are absolutely sure of this, as it makes the
|
||||
operation slower and is less friendly for the network. */
|
||||
CURLOPT(CURLOPT_FRESH_CONNECT, CURLOPTTYPE_LONG, 74),
|
||||
|
||||
/* Set to explicitly forbid the upcoming transfer's connection to be reused
|
||||
when done. Do not use this unless you're absolutely sure of this, as it
|
||||
when done. Do not use this unless you are absolutely sure of this, as it
|
||||
makes the operation slower and is less friendly for the network. */
|
||||
CURLOPT(CURLOPT_FORBID_REUSE, CURLOPTTYPE_LONG, 75),
|
||||
|
||||
/* Set to a file name that contains random data for libcurl to use to
|
||||
/* Set to a filename that contains random data for libcurl to use to
|
||||
seed the random engine when doing SSL connects. */
|
||||
CURLOPTDEPRECATED(CURLOPT_RANDOM_FILE, CURLOPTTYPE_STRINGPOINT, 76,
|
||||
7.84.0, "Serves no purpose anymore"),
|
||||
|
|
@ -1394,8 +1394,8 @@ typedef enum {
|
|||
* provided hostname. */
|
||||
CURLOPT(CURLOPT_SSL_VERIFYHOST, CURLOPTTYPE_LONG, 81),
|
||||
|
||||
/* Specify which file name to write all known cookies in after completed
|
||||
operation. Set file name to "-" (dash) to make it go to stdout. */
|
||||
/* Specify which filename to write all known cookies in after completed
|
||||
operation. Set filename to "-" (dash) to make it go to stdout. */
|
||||
CURLOPT(CURLOPT_COOKIEJAR, CURLOPTTYPE_STRINGPOINT, 82),
|
||||
|
||||
/* Specify which SSL ciphers to use */
|
||||
|
|
@ -1514,7 +1514,7 @@ typedef enum {
|
|||
CURLOPT(CURLOPT_PROXYAUTH, CURLOPTTYPE_VALUES, 111),
|
||||
|
||||
/* Option that changes the timeout, in seconds, associated with getting a
|
||||
response. This is different from transfer timeout time and essentially
|
||||
response. This is different from transfer timeout time and essentially
|
||||
places a demand on the server to acknowledge commands in a timely
|
||||
manner. For FTP, SMTP, IMAP and POP3. */
|
||||
CURLOPT(CURLOPT_SERVER_RESPONSE_TIMEOUT, CURLOPTTYPE_LONG, 112),
|
||||
|
|
@ -1528,7 +1528,7 @@ typedef enum {
|
|||
an HTTP or FTP server.
|
||||
|
||||
Note there is also _LARGE version which adds large file support for
|
||||
platforms which have larger off_t sizes. See MAXFILESIZE_LARGE below. */
|
||||
platforms which have larger off_t sizes. See MAXFILESIZE_LARGE below. */
|
||||
CURLOPT(CURLOPT_MAXFILESIZE, CURLOPTTYPE_LONG, 114),
|
||||
|
||||
/* See the comment for INFILESIZE above, but in short, specifies
|
||||
|
|
@ -1536,17 +1536,17 @@ typedef enum {
|
|||
*/
|
||||
CURLOPT(CURLOPT_INFILESIZE_LARGE, CURLOPTTYPE_OFF_T, 115),
|
||||
|
||||
/* Sets the continuation offset. There is also a CURLOPTTYPE_LONG version
|
||||
/* Sets the continuation offset. There is also a CURLOPTTYPE_LONG version
|
||||
* of this; look above for RESUME_FROM.
|
||||
*/
|
||||
CURLOPT(CURLOPT_RESUME_FROM_LARGE, CURLOPTTYPE_OFF_T, 116),
|
||||
|
||||
/* Sets the maximum size of data that will be downloaded from
|
||||
* an HTTP or FTP server. See MAXFILESIZE above for the LONG version.
|
||||
* an HTTP or FTP server. See MAXFILESIZE above for the LONG version.
|
||||
*/
|
||||
CURLOPT(CURLOPT_MAXFILESIZE_LARGE, CURLOPTTYPE_OFF_T, 117),
|
||||
|
||||
/* Set this option to the file name of your .netrc file you want libcurl
|
||||
/* Set this option to the filename of your .netrc file you want libcurl
|
||||
to parse (using the CURLOPT_NETRC option). If not set, libcurl will do
|
||||
a poor attempt to find the user's home directory and check for a .netrc
|
||||
file in there. */
|
||||
|
|
@ -1693,7 +1693,7 @@ typedef enum {
|
|||
|
||||
/* Callback function for opening socket (instead of socket(2)). Optionally,
|
||||
callback is able change the address or refuse to connect returning
|
||||
CURL_SOCKET_BAD. The callback should have type
|
||||
CURL_SOCKET_BAD. The callback should have type
|
||||
curl_opensocket_callback */
|
||||
CURLOPT(CURLOPT_OPENSOCKETFUNCTION, CURLOPTTYPE_FUNCTIONPOINT, 163),
|
||||
CURLOPT(CURLOPT_OPENSOCKETDATA, CURLOPTTYPE_CBPOINT, 164),
|
||||
|
|
@ -1763,7 +1763,7 @@ typedef enum {
|
|||
CURLOPTDEPRECATED(CURLOPT_REDIR_PROTOCOLS, CURLOPTTYPE_LONG, 182,
|
||||
7.85.0, "Use CURLOPT_REDIR_PROTOCOLS_STR"),
|
||||
|
||||
/* set the SSH knownhost file name to use */
|
||||
/* set the SSH knownhost filename to use */
|
||||
CURLOPT(CURLOPT_SSH_KNOWNHOSTS, CURLOPTTYPE_STRINGPOINT, 183),
|
||||
|
||||
/* set the SSH host key callback, must point to a curl_sshkeycallback
|
||||
|
|
@ -1844,7 +1844,7 @@ typedef enum {
|
|||
future libcurl release.
|
||||
|
||||
libcurl will ask for the compressed methods it knows of, and if that
|
||||
isn't any, it will not ask for transfer-encoding at all even if this
|
||||
is not any, it will not ask for transfer-encoding at all even if this
|
||||
option is set to 1.
|
||||
|
||||
*/
|
||||
|
|
@ -1946,7 +1946,7 @@ typedef enum {
|
|||
/* Service Name */
|
||||
CURLOPT(CURLOPT_SERVICE_NAME, CURLOPTTYPE_STRINGPOINT, 236),
|
||||
|
||||
/* Wait/don't wait for pipe/mutex to clarify */
|
||||
/* Wait/do not wait for pipe/mutex to clarify */
|
||||
CURLOPT(CURLOPT_PIPEWAIT, CURLOPTTYPE_LONG, 237),
|
||||
|
||||
/* Set the protocol used when curl is given a URL without a protocol */
|
||||
|
|
@ -2107,7 +2107,7 @@ typedef enum {
|
|||
/* alt-svc control bitmask */
|
||||
CURLOPT(CURLOPT_ALTSVC_CTRL, CURLOPTTYPE_LONG, 286),
|
||||
|
||||
/* alt-svc cache file name to possibly read from/write to */
|
||||
/* alt-svc cache filename to possibly read from/write to */
|
||||
CURLOPT(CURLOPT_ALTSVC, CURLOPTTYPE_STRINGPOINT, 287),
|
||||
|
||||
/* maximum age (idle time) of a connection to consider it for reuse
|
||||
|
|
@ -2139,7 +2139,7 @@ typedef enum {
|
|||
|
||||
/* HSTS bitmask */
|
||||
CURLOPT(CURLOPT_HSTS_CTRL, CURLOPTTYPE_LONG, 299),
|
||||
/* HSTS file name */
|
||||
/* HSTS filename */
|
||||
CURLOPT(CURLOPT_HSTS, CURLOPTTYPE_STRINGPOINT, 300),
|
||||
|
||||
/* HSTS read callback */
|
||||
|
|
@ -2274,9 +2274,9 @@ typedef enum {
|
|||
|
||||
/* These enums are for use with the CURLOPT_HTTP_VERSION option. */
|
||||
enum {
|
||||
CURL_HTTP_VERSION_NONE, /* setting this means we don't care, and that we'd
|
||||
like the library to choose the best possible
|
||||
for us! */
|
||||
CURL_HTTP_VERSION_NONE, /* setting this means we do not care, and that we
|
||||
would like the library to choose the best
|
||||
possible for us! */
|
||||
CURL_HTTP_VERSION_1_0, /* please use HTTP 1.0 in the request */
|
||||
CURL_HTTP_VERSION_1_1, /* please use HTTP 1.1 in the request */
|
||||
CURL_HTTP_VERSION_2_0, /* please use HTTP 2 in the request */
|
||||
|
|
@ -2436,7 +2436,7 @@ CURL_EXTERN CURLcode curl_mime_name(curl_mimepart *part, const char *name);
|
|||
*
|
||||
* DESCRIPTION
|
||||
*
|
||||
* Set mime part remote file name.
|
||||
* Set mime part remote filename.
|
||||
*/
|
||||
CURL_EXTERN CURLcode curl_mime_filename(curl_mimepart *part,
|
||||
const char *filename);
|
||||
|
|
@ -2717,10 +2717,10 @@ CURL_EXTERN CURLcode curl_global_init(long flags);
|
|||
* DESCRIPTION
|
||||
*
|
||||
* curl_global_init() or curl_global_init_mem() should be invoked exactly once
|
||||
* for each application that uses libcurl. This function can be used to
|
||||
* for each application that uses libcurl. This function can be used to
|
||||
* initialize libcurl and set user defined memory management callback
|
||||
* functions. Users can implement memory management routines to check for
|
||||
* memory leaks, check for mis-use of the curl library etc. User registered
|
||||
* functions. Users can implement memory management routines to check for
|
||||
* memory leaks, check for mis-use of the curl library etc. User registered
|
||||
* callback routines will be invoked by this library instead of the system
|
||||
* memory management routines like malloc, free etc.
|
||||
*/
|
||||
|
|
@ -2838,7 +2838,7 @@ CURL_EXTERN time_t curl_getdate(const char *p, const time_t *unused);
|
|||
for with CURLOPT_CERTINFO / CURLINFO_CERTINFO */
|
||||
struct curl_certinfo {
|
||||
int num_of_certs; /* number of certificates with information */
|
||||
struct curl_slist **certinfo; /* for each index in this array, there's a
|
||||
struct curl_slist **certinfo; /* for each index in this array, there is a
|
||||
linked list with textual information for a
|
||||
certificate in the format "name:content".
|
||||
eg "Subject:foo", "Issuer:bar", etc. */
|
||||
|
|
@ -3029,7 +3029,7 @@ typedef enum {
|
|||
} CURLSHcode;
|
||||
|
||||
typedef enum {
|
||||
CURLSHOPT_NONE, /* don't use */
|
||||
CURLSHOPT_NONE, /* do not use */
|
||||
CURLSHOPT_SHARE, /* specify a data type to share */
|
||||
CURLSHOPT_UNSHARE, /* specify which data type to stop sharing */
|
||||
CURLSHOPT_LOCKFUNC, /* pass in a 'curl_lock_function' pointer */
|
||||
|
|
@ -3188,7 +3188,7 @@ CURL_EXTERN curl_version_info_data *curl_version_info(CURLversion);
|
|||
* DESCRIPTION
|
||||
*
|
||||
* The curl_easy_strerror function may be used to turn a CURLcode value
|
||||
* into the equivalent human readable error string. This is useful
|
||||
* into the equivalent human readable error string. This is useful
|
||||
* for printing meaningful error messages.
|
||||
*/
|
||||
CURL_EXTERN const char *curl_easy_strerror(CURLcode);
|
||||
|
|
@ -3199,7 +3199,7 @@ CURL_EXTERN const char *curl_easy_strerror(CURLcode);
|
|||
* DESCRIPTION
|
||||
*
|
||||
* The curl_share_strerror function may be used to turn a CURLSHcode value
|
||||
* into the equivalent human readable error string. This is useful
|
||||
* into the equivalent human readable error string. This is useful
|
||||
* for printing meaningful error messages.
|
||||
*/
|
||||
CURL_EXTERN const char *curl_share_strerror(CURLSHcode);
|
||||
|
|
@ -3238,7 +3238,7 @@ CURL_EXTERN CURLcode curl_easy_pause(CURL *handle, int bitmask);
|
|||
#include "websockets.h"
|
||||
#include "mprintf.h"
|
||||
|
||||
/* the typechecker doesn't work in C++ (yet) */
|
||||
/* the typechecker does not work in C++ (yet) */
|
||||
#if defined(__GNUC__) && defined(__GNUC_MINOR__) && \
|
||||
((__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)) && \
|
||||
!defined(__cplusplus) && !defined(CURL_DISABLE_TYPECHECK)
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@
|
|||
|
||||
Where XX, YY and ZZ are the main version, release and patch numbers in
|
||||
hexadecimal (using 8 bits each). All three numbers are always represented
|
||||
using two digits. 1.2 would appear as "0x010200" while version 9.11.7
|
||||
using two digits. 1.2 would appear as "0x010200" while version 9.11.7
|
||||
appears as "0x090b07".
|
||||
|
||||
This 6-digit (24 bits) hexadecimal number does not show pre-release number,
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ CURL_EXTERN void curl_easy_cleanup(CURL *curl);
|
|||
*
|
||||
* Request internal information from the curl session with this function.
|
||||
* The third argument MUST be pointing to the specific type of the used option
|
||||
* which is documented in each man page of the option. The data pointed to
|
||||
* which is documented in each manpage of the option. The data pointed to
|
||||
* will be filled in accordingly and can be relied upon only if the function
|
||||
* returns CURLE_OK. This function is intended to get used *AFTER* a performed
|
||||
* transfer, all results from this function are undefined until the transfer
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@
|
|||
*
|
||||
***************************************************************************/
|
||||
/*
|
||||
This is an "external" header file. Don't give away any internals here!
|
||||
This is an "external" header file. Do not give away any internals here!
|
||||
|
||||
GOALS
|
||||
|
||||
|
|
@ -66,7 +66,7 @@ typedef enum {
|
|||
CURLM_OK,
|
||||
CURLM_BAD_HANDLE, /* the passed-in handle is not a valid CURLM handle */
|
||||
CURLM_BAD_EASY_HANDLE, /* an easy handle was not good/valid */
|
||||
CURLM_OUT_OF_MEMORY, /* if you ever get this, you're in deep sh*t */
|
||||
CURLM_OUT_OF_MEMORY, /* if you ever get this, you are in deep sh*t */
|
||||
CURLM_INTERNAL_ERROR, /* this is a libcurl bug */
|
||||
CURLM_BAD_SOCKET, /* the passed in socket argument did not match */
|
||||
CURLM_UNKNOWN_OPTION, /* curl_multi_setopt() with unsupported option */
|
||||
|
|
@ -109,7 +109,7 @@ struct CURLMsg {
|
|||
typedef struct CURLMsg CURLMsg;
|
||||
|
||||
/* Based on poll(2) structure and values.
|
||||
* We don't use pollfd and POLL* constants explicitly
|
||||
* We do not use pollfd and POLL* constants explicitly
|
||||
* to cover platforms without poll(). */
|
||||
#define CURL_WAIT_POLLIN 0x0001
|
||||
#define CURL_WAIT_POLLPRI 0x0002
|
||||
|
|
@ -205,7 +205,7 @@ CURL_EXTERN CURLMcode curl_multi_wakeup(CURLM *multi_handle);
|
|||
/*
|
||||
* Name: curl_multi_perform()
|
||||
*
|
||||
* Desc: When the app thinks there's data available for curl it calls this
|
||||
* Desc: When the app thinks there is data available for curl it calls this
|
||||
* function to read/write whatever there is right now. This returns
|
||||
* as soon as the reads and writes are done. This function does not
|
||||
* require that there actually is data available for reading or that
|
||||
|
|
@ -236,7 +236,7 @@ CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle);
|
|||
/*
|
||||
* Name: curl_multi_info_read()
|
||||
*
|
||||
* Desc: Ask the multi handle if there's any messages/informationals from
|
||||
* Desc: Ask the multi handle if there is any messages/informationals from
|
||||
* the individual transfers. Messages include informationals such as
|
||||
* error code from the transfer or just the fact that a transfer is
|
||||
* completed. More details on these should be written down as well.
|
||||
|
|
@ -253,7 +253,7 @@ CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle);
|
|||
* we will provide the particular "transfer handle" in that struct
|
||||
* and that should/could/would be used in subsequent
|
||||
* curl_easy_getinfo() calls (or similar). The point being that we
|
||||
* must never expose complex structs to applications, as then we'll
|
||||
* must never expose complex structs to applications, as then we will
|
||||
* undoubtably get backwards compatibility problems in the future.
|
||||
*
|
||||
* Returns: A pointer to a filled-in struct, or NULL if it failed or ran out
|
||||
|
|
@ -268,7 +268,7 @@ CURL_EXTERN CURLMsg *curl_multi_info_read(CURLM *multi_handle,
|
|||
* Name: curl_multi_strerror()
|
||||
*
|
||||
* Desc: The curl_multi_strerror function may be used to turn a CURLMcode
|
||||
* value into the equivalent human readable error string. This is
|
||||
* value into the equivalent human readable error string. This is
|
||||
* useful for printing meaningful error messages.
|
||||
*
|
||||
* Returns: A pointer to a null-terminated error message.
|
||||
|
|
@ -282,7 +282,7 @@ CURL_EXTERN const char *curl_multi_strerror(CURLMcode);
|
|||
* Desc: An alternative version of curl_multi_perform() that allows the
|
||||
* application to pass in one of the file descriptors that have been
|
||||
* detected to have "action" on them and let libcurl perform.
|
||||
* See man page for details.
|
||||
* See manpage for details.
|
||||
*/
|
||||
#define CURL_POLL_NONE 0
|
||||
#define CURL_POLL_IN 1
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@
|
|||
* As a general rule, curl_off_t shall not be mapped to off_t. This rule shall
|
||||
* only be violated if off_t is the only 64-bit data type available and the
|
||||
* size of off_t is independent of large file support settings. Keep your
|
||||
* build on the safe side avoiding an off_t gating. If you have a 64-bit
|
||||
* build on the safe side avoiding an off_t gating. If you have a 64-bit
|
||||
* off_t then take for sure that another 64-bit data type exists, dig deeper
|
||||
* and you will find it.
|
||||
*
|
||||
|
|
@ -402,7 +402,7 @@
|
|||
# define CURL_PULL_SYS_SOCKET_H 1
|
||||
|
||||
#else
|
||||
/* generic "safe guess" on old 32 bit style */
|
||||
/* generic "safe guess" on old 32-bit style */
|
||||
# define CURL_TYPEOF_CURL_OFF_T long
|
||||
# define CURL_FORMAT_CURL_OFF_T "ld"
|
||||
# define CURL_FORMAT_CURL_OFF_TU "lu"
|
||||
|
|
|
|||
|
|
@ -34,11 +34,11 @@
|
|||
* _curl_easy_setopt_err_sometype below
|
||||
*
|
||||
* NOTE: We use two nested 'if' statements here instead of the && operator, in
|
||||
* order to work around gcc bug #32061. It affects only gcc 4.3.x/4.4.x
|
||||
* order to work around gcc bug #32061. It affects only gcc 4.3.x/4.4.x
|
||||
* when compiling with -Wlogical-op.
|
||||
*
|
||||
* To add an option that uses the same type as an existing option, you'll just
|
||||
* need to extend the appropriate _curl_*_option macro
|
||||
* To add an option that uses the same type as an existing option, you will
|
||||
* just need to extend the appropriate _curl_*_option macro
|
||||
*/
|
||||
#define curl_easy_setopt(handle, option, value) \
|
||||
__extension__({ \
|
||||
|
|
@ -245,7 +245,7 @@ CURLWARNING(_curl_easy_getinfo_err_curl_off_t,
|
|||
|
||||
/* To add a new option to one of the groups, just add
|
||||
* (option) == CURLOPT_SOMETHING
|
||||
* to the or-expression. If the option takes a long or curl_off_t, you don't
|
||||
* to the or-expression. If the option takes a long or curl_off_t, you do not
|
||||
* have to do anything
|
||||
*/
|
||||
|
||||
|
|
@ -678,7 +678,7 @@ typedef CURLcode (*_curl_ssl_ctx_callback4)(CURL *, const void *,
|
|||
const void *);
|
||||
#ifdef HEADER_SSL_H
|
||||
/* hack: if we included OpenSSL's ssl.h, we know about SSL_CTX
|
||||
* this will of course break if we're included before OpenSSL headers...
|
||||
* this will of course break if we are included before OpenSSL headers...
|
||||
*/
|
||||
typedef CURLcode (*_curl_ssl_ctx_callback5)(CURL *, SSL_CTX *, void *);
|
||||
typedef CURLcode (*_curl_ssl_ctx_callback6)(CURL *, SSL_CTX *, const void *);
|
||||
|
|
|
|||
|
|
@ -97,12 +97,12 @@ typedef enum {
|
|||
#define CURLU_NO_AUTHORITY (1<<10) /* Allow empty authority when the
|
||||
scheme is unknown. */
|
||||
#define CURLU_ALLOW_SPACE (1<<11) /* Allow spaces in the URL */
|
||||
#define CURLU_PUNYCODE (1<<12) /* get the host name in punycode */
|
||||
#define CURLU_PUNYCODE (1<<12) /* get the hostname in punycode */
|
||||
#define CURLU_PUNY2IDN (1<<13) /* punycode => IDN conversion */
|
||||
#define CURLU_GET_EMPTY (1<<14) /* allow empty queries and fragments
|
||||
when extracting the URL or the
|
||||
components */
|
||||
#define CURLU_NO_GUESS_SCHEME (1<<15) /* for get, don't accept a guess */
|
||||
#define CURLU_NO_GUESS_SCHEME (1<<15) /* for get, do not accept a guess */
|
||||
|
||||
typedef struct Curl_URL CURLU;
|
||||
|
||||
|
|
@ -143,7 +143,7 @@ CURL_EXTERN CURLUcode curl_url_set(CURLU *handle, CURLUPart what,
|
|||
|
||||
/*
|
||||
* curl_url_strerror() turns a CURLUcode value into the equivalent human
|
||||
* readable error string. This is useful for printing meaningful error
|
||||
* readable error string. This is useful for printing meaningful error
|
||||
* messages.
|
||||
*/
|
||||
CURL_EXTERN const char *curl_url_strerror(CURLUcode);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue