cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: [PATCH] curl_darwinssl.c: unsafe use of strtok

From: Toby Peterson <toby_at_apple.com>
Date: Mon, 04 Aug 2014 14:25:57 -0700

On Aug 4, 2014, at 14:23, Toby Peterson <toby_at_apple.com> wrote:

> The GetDarwinVersionNumber() function uses strtok, which is not thread-safe. Simple patch attached (based on 7.37.1).
>
> - Toby
> <darwinssl-strtok.diff>

It occurs to me that this should probably add #include "strtok.h" for platforms that don't have strtok_r, but I have no easy way to verify that.

- Toby
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2014-08-04