os/persistentdata/persistentstorage/sqlite3api/TEST/TCL/tcldistribution/compat/fixstrtod.c
First public contribution.
4 * Source code for the "fixstrtod" procedure. This procedure is
5 * used in place of strtod under Solaris 2.4, in order to fix
6 * a bug where the "end" pointer gets set incorrectly.
8 * Copyright (c) 1995 Sun Microsystems, Inc.
10 * See the file "license.terms" for information on usage and redistribution
11 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
13 * RCS: @(#) $Id: fixstrtod.c,v 1.2 1998/09/14 18:39:44 stanton Exp $
21 * Declare strtod explicitly rather than including stdlib.h, since in
22 * somes systems (e.g. SunOS 4.1.4) stdlib.h doesn't declare strtod.
25 extern double strtod();
28 fixstrtod(string, endPtr)
33 d = strtod(string, endPtr);
34 if ((endPtr != NULL) && (*endPtr != string) && ((*endPtr)[-1] == 0)) {