size_t is guaranteed only to be at least 16 bits according to the
standard

Have you ever seen libcurl run on a system with size_t being 16 bit?

Well, no.  Still, some of those systems are pretty obscure.

This is what you need:

if (CURL_MAX_WRITE_SIZE > (size_t) -1)
{
   // potential buffer overflow
}

Richard


-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html

Reply via email to