ERR: Attempt to remove warnings
This commit is contained in:
parent
1328164208
commit
1b7ba8bdd9
|
@ -80,13 +80,13 @@
|
||||||
#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII))
|
#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII))
|
||||||
# define IN_CTYPE_DOMAIN(c) 1
|
# define IN_CTYPE_DOMAIN(c) 1
|
||||||
#else
|
#else
|
||||||
# define IN_CTYPE_DOMAIN(c) isascii(c)
|
# define IN_CTYPE_DOMAIN(c) isascii((int)(c))
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define ISSPACE(c) (IN_CTYPE_DOMAIN (c) && isspace (c))
|
#define ISSPACE(c) (IN_CTYPE_DOMAIN (c) && isspace ((int)(c)))
|
||||||
#define ISALPHA(c) (IN_CTYPE_DOMAIN (c) && isalpha (c))
|
#define ISALPHA(c) (IN_CTYPE_DOMAIN (c) && isalpha ((int)(c)))
|
||||||
#define ISUPPER(c) (IN_CTYPE_DOMAIN (c) && isupper (c))
|
#define ISUPPER(c) (IN_CTYPE_DOMAIN (c) && isupper ((int)(c)))
|
||||||
#define ISDIGIT_LOCALE(c) (IN_CTYPE_DOMAIN (c) && isdigit (c))
|
#define ISDIGIT_LOCALE(c) (IN_CTYPE_DOMAIN (c) && isdigit ((int)(c)))
|
||||||
|
|
||||||
/* ISDIGIT differs from ISDIGIT_LOCALE, as follows:
|
/* ISDIGIT differs from ISDIGIT_LOCALE, as follows:
|
||||||
- Its arg may be any int or unsigned int; it need not be an unsigned char.
|
- Its arg may be any int or unsigned int; it need not be an unsigned char.
|
||||||
|
|
|
@ -407,7 +407,7 @@ static void hostcache_fixoffset(struct hostent *h, int offset);
|
||||||
static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
||||||
{
|
{
|
||||||
char *bufptr;
|
char *bufptr;
|
||||||
char *newbuf;
|
struct hostent *newbuf;
|
||||||
struct hostent* copy;
|
struct hostent* copy;
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
|
@ -415,7 +415,7 @@ static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
||||||
size_t len;
|
size_t len;
|
||||||
|
|
||||||
bufptr = *buf;
|
bufptr = *buf;
|
||||||
copy = (struct hostent*)bufptr;
|
memcpy(©, &bufptr, sizeof(struct hostent*));
|
||||||
|
|
||||||
bufptr += sizeof(struct hostent);
|
bufptr += sizeof(struct hostent);
|
||||||
copy->h_name = bufptr;
|
copy->h_name = bufptr;
|
||||||
|
@ -429,7 +429,7 @@ static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
||||||
/* This must be aligned properly to work on many CPU architectures! */
|
/* This must be aligned properly to work on many CPU architectures! */
|
||||||
bufptr = MEMALIGN(bufptr);
|
bufptr = MEMALIGN(bufptr);
|
||||||
|
|
||||||
copy->h_aliases = (char**)bufptr;
|
memcpy(©->h_aliases, &bufptr, sizeof(char**));
|
||||||
|
|
||||||
/* Figure out how many aliases there are */
|
/* Figure out how many aliases there are */
|
||||||
for (i = 0; orig->h_aliases[i] != NULL; ++i);
|
for (i = 0; orig->h_aliases[i] != NULL; ++i);
|
||||||
|
@ -453,7 +453,7 @@ static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
||||||
/* align it for (at least) 32bit accesses */
|
/* align it for (at least) 32bit accesses */
|
||||||
bufptr = MEMALIGN(bufptr);
|
bufptr = MEMALIGN(bufptr);
|
||||||
|
|
||||||
copy->h_addr_list = (char**)bufptr;
|
memcpy(©->h_addr_list, &bufptr, sizeof(char**));
|
||||||
|
|
||||||
/* Figure out how many addresses there are */
|
/* Figure out how many addresses there are */
|
||||||
for (i = 0; orig->h_addr_list[i] != NULL; ++i);
|
for (i = 0; orig->h_addr_list[i] != NULL; ++i);
|
||||||
|
@ -474,7 +474,7 @@ static struct hostent* pack_hostent(char** buf, struct hostent* orig)
|
||||||
|
|
||||||
/* now, shrink the allocated buffer to the size we actually need, which
|
/* now, shrink the allocated buffer to the size we actually need, which
|
||||||
most often is only a fraction of the original alloc */
|
most often is only a fraction of the original alloc */
|
||||||
newbuf=(char *)realloc(*buf, (int)bufptr-(int)(*buf));
|
newbuf=(struct hostent *)realloc(*buf, (int)bufptr-(int)(*buf));
|
||||||
|
|
||||||
/* if the alloc moved, we need to adjust things again */
|
/* if the alloc moved, we need to adjust things again */
|
||||||
if(newbuf != *buf)
|
if(newbuf != *buf)
|
||||||
|
|
|
@ -2033,7 +2033,7 @@ static CURLcode CreateConnection(struct SessionHandle *data,
|
||||||
|
|
||||||
/* Now, build <protocol>_proxy and check for such a one to use */
|
/* Now, build <protocol>_proxy and check for such a one to use */
|
||||||
while(*protop)
|
while(*protop)
|
||||||
*envp++ = (char)tolower(*protop++);
|
*envp++ = (char)tolower((int)*protop++);
|
||||||
|
|
||||||
/* append _proxy */
|
/* append _proxy */
|
||||||
strcpy(envp, "_proxy");
|
strcpy(envp, "_proxy");
|
||||||
|
@ -2056,7 +2056,7 @@ static CURLcode CreateConnection(struct SessionHandle *data,
|
||||||
if(!prox && !strequal("http_proxy", proxy_env)) {
|
if(!prox && !strequal("http_proxy", proxy_env)) {
|
||||||
/* There was no lowercase variable, try the uppercase version: */
|
/* There was no lowercase variable, try the uppercase version: */
|
||||||
for(envp = proxy_env; *envp; envp++)
|
for(envp = proxy_env; *envp; envp++)
|
||||||
*envp = (char)toupper(*envp);
|
*envp = (char)toupper((int)*envp);
|
||||||
prox=curl_getenv(proxy_env);
|
prox=curl_getenv(proxy_env);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2239,7 +2239,7 @@ static CURLcode CreateConnection(struct SessionHandle *data,
|
||||||
if(type) {
|
if(type) {
|
||||||
char command;
|
char command;
|
||||||
*type=0; /* it was in the middle of the hostname */
|
*type=0; /* it was in the middle of the hostname */
|
||||||
command = (char)toupper(type[6]);
|
command = (char)toupper((int)type[6]);
|
||||||
switch(command) {
|
switch(command) {
|
||||||
case 'A': /* ASCII mode */
|
case 'A': /* ASCII mode */
|
||||||
data->set.ftp_ascii = 1;
|
data->set.ftp_ascii = 1;
|
||||||
|
|
Loading…
Reference in New Issue