Commit 6b1220b6 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

Cory Nelson's work on nuking compiler warnings when building on x64 with

VS2005.
parent 9d7330d8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -652,7 +652,7 @@ singleipconnect(struct connectdata *conn,
  /* set socket non-blocking */
  Curl_nonblock(sockfd, TRUE);

  rc = connect(sockfd, ai->ai_addr, ai->ai_addrlen);
  rc = connect(sockfd, ai->ai_addr, (socklen_t)ai->ai_addrlen);

  if(-1 == rc) {
    error = Curl_ourerrno();
+2 −2
Original line number Diff line number Diff line
@@ -309,7 +309,7 @@ Curl_cookie_add(struct SessionHandle *data,
              break;
            }
            co->expires =
              atoi((*co->maxage=='\"')?&co->maxage[1]:&co->maxage[0]) + now;
              atoi((*co->maxage=='\"')?&co->maxage[1]:&co->maxage[0]) + (long)now;
          }
          else if(strequal("expires", name)) {
            co->expirestr=strdup(whatptr);
@@ -317,7 +317,7 @@ Curl_cookie_add(struct SessionHandle *data,
              badcookie = TRUE;
              break;
            }
            co->expires = curl_getdate(what, &now);
            co->expires = (long)curl_getdate(what, &now);
          }
          else if(!co->name) {
            co->name = strdup(name);
+2 −2
Original line number Diff line number Diff line
@@ -464,7 +464,7 @@ CURLFORMcode FormAdd(struct curl_httppost **httppost,
        return_value = CURL_FORMADD_OPTION_TWICE;
      else
        current_form->namelength =
          array_state?(long)array_value:va_arg(params, long);
          array_state?(long)array_value:(long)va_arg(params, long);
      break;

      /*
@@ -1550,7 +1550,7 @@ char *Curl_FormBoundary(void)
  if(!retstring)
    return NULL; /* failed */

  srand(time(NULL)+randomizer++); /* seed */
  srand((unsigned int)time(NULL)+randomizer++); /* seed */

  strcpy(retstring, "----------------------------");

+4 −4
Original line number Diff line number Diff line
@@ -266,8 +266,8 @@ static CURLcode ftp_readresp(curl_socket_t sockfd,

  ptr=buf + ftp->nread_resp;

  perline= ptr-ftp->linestart_resp; /* number of bytes in the current line,
                                       so far */
  perline= (int)(ptr-ftp->linestart_resp); /* number of bytes in the current
                                              line, so far */
  keepon=TRUE;

  while((ftp->nread_resp<BUFSIZE) && (keepon && !result)) {
@@ -1739,7 +1739,7 @@ static CURLcode ftp_state_mdtm_resp(struct connectdata *conn,
                 "%04d%02d%02d %02d:%02d:%02d GMT",
                 year, month, day, hour, minute, second);
        /* now, convert this into a time() value: */
        data->info.filetime = curl_getdate(buf, &secs);
        data->info.filetime = (long)curl_getdate(buf, &secs);
      }

      /* If we asked for a time of the file and we actually got one as well,
@@ -2086,7 +2086,7 @@ static CURLcode ftp_state_get_resp(struct connectdata *conn,
      char *bytes;
      bytes=strstr(buf, " bytes");
      if(bytes--) {
        long in=bytes-buf;
        long in=(long)(bytes-buf);
        /* this is a hint there is size information in there! ;-) */
        while(--in) {
          /* scan for the left parenthesis and break there */
+1 −1
Original line number Diff line number Diff line
@@ -548,7 +548,7 @@ CURLcode Curl_resolv_fdset(struct connectdata *conn,

  if (td && td->dummy_sock != CURL_SOCKET_BAD) {
    FD_SET(td->dummy_sock,write_fd_set);
    *max_fdp = td->dummy_sock;
    *max_fdp = (int)td->dummy_sock;
  }
  (void) read_fd_set;
  return CURLE_OK;
Loading