cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Issue with http_chunks.c

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sat, 19 Jul 2014 23:36:07 +0200 (CEST)

On Sat, 19 Jul 2014, Glen A Johnson Jr. wrote:

> This issue was discovered when running with a 64bit compilation.
>
> The assignment of a ssize_t pointer from the parameter list to a size_t
> pointer in the function causes stack corruption when data is assigned to the
> variables location during 64bit execution.

How does that happen? Are you suggesting size_t and ssize_t use different
sizes for you?

> The diff file attached shows one method to correct the issue. A simpler
> method would be to eliminate the variable "wrote" and use "*wrotep +=
> (ssize_t)piece;" at ~line 237.

Can you elaborate on what is needed and why, in plain English? Also, what can
we do to repeat the problem you saw with this?

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2014-07-19