diff options
author | patthoyts@users.sourceforge.net <patthoyts> | 2007-09-19 10:54:19 (GMT) |
---|---|---|
committer | patthoyts@users.sourceforge.net <patthoyts> | 2007-09-19 10:54:19 (GMT) |
commit | 38e2e53a5f07d4f257f9453307184f438e74c96d (patch) | |
tree | acac58e6ad8b71e32db3676982410796be555cb0 /generic | |
parent | 76ad9b6b198d9c7087403e0b2837daab998b562f (diff) | |
download | tk-38e2e53a5f07d4f257f9453307184f438e74c96d.zip tk-38e2e53a5f07d4f257f9453307184f438e74c96d.tar.gz tk-38e2e53a5f07d4f257f9453307184f438e74c96d.tar.bz2 |
Replace isdigit call with an internal implementation to avoid libc linkage on windows
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tkStubLib.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/generic/tkStubLib.c b/generic/tkStubLib.c index aaeba9f..cfcaffd 100644 --- a/generic/tkStubLib.c +++ b/generic/tkStubLib.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkStubLib.c,v 1.17 2007/09/18 16:12:19 dgp Exp $ + * RCS: @(#) $Id: tkStubLib.c,v 1.18 2007/09/19 10:54:20 patthoyts Exp $ */ /* @@ -55,6 +55,15 @@ TkIntPlatStubs *tkIntPlatStubsPtr; TkIntXlibStubs *tkIntXlibStubsPtr; /* + * Use our own isdigit to avoid linking to libc on windows + */ + +static int isDigit(const int c) +{ + return (c >= '0' && c <= '9'); +} + +/* *---------------------------------------------------------------------- * * Tk_InitStubs -- @@ -95,7 +104,7 @@ Tk_InitStubs( int count = 0; while (*p) { - count += !isdigit(*p++); + count += !isDigit(*p++); } if (count == 1) { CONST char *q = actualVersion; |