From 80cc55de746612ae38dfdf0f70e6a31235a5e041 Mon Sep 17 00:00:00 2001 From: Magnus Olsen Date: Sun, 25 Dec 2005 18:53:39 +0000 Subject: [PATCH] do not BSD in some test apps I have. it did not check if input buffer for the convert string was NULL or not. svn path=/trunk/; revision=20330 --- reactos/lib/crt/stdlib/strtod.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/reactos/lib/crt/stdlib/strtod.c b/reactos/lib/crt/stdlib/strtod.c index 0dea5ff7ac0..3d40f56fcd3 100644 --- a/reactos/lib/crt/stdlib/strtod.c +++ b/reactos/lib/crt/stdlib/strtod.c @@ -21,6 +21,10 @@ strtod(const char *s, char **sret) sign = 1; e = 0; esign = 1; + + if (s == NULL) + return r; + while ((*s == ' ') || (*s == '\t')) s++;