X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=functions%2F_PDCLIB%2Fstrtox_prelim.c;h=6e16b35d17f41c36528ae3b1bc773fbbac13cfbf;hb=d865c4403fc91d1f1ac95ba76febcee9f429bb97;hp=6ff75c1282bf4021735e97e460e4f405d929d9cf;hpb=b1fc26afebd4d557ff89a44bc21767a8704c3809;p=pdclib diff --git a/functions/_PDCLIB/strtox_prelim.c b/functions/_PDCLIB/strtox_prelim.c index 6ff75c1..6e16b35 100644 --- a/functions/_PDCLIB/strtox_prelim.c +++ b/functions/_PDCLIB/strtox_prelim.c @@ -8,6 +8,8 @@ #include #include +#ifndef REGTEST + const char * _PDCLIB_strtox_prelim( const char * p, char * sign, int * base ) { /* skipping leading whitespace */ @@ -49,11 +51,15 @@ const char * _PDCLIB_strtox_prelim( const char * p, char * sign, int * base ) return ( ( *base >= 2 ) && ( *base <= 36 ) ) ? p : NULL; } +#endif + #ifdef TEST -#include <_PDCLIB_test.h> + +#include "_PDCLIB_test.h" int main( void ) { +#ifndef REGTEST int base = 0; char sign = '\0'; char test1[] = " 123"; @@ -81,6 +87,7 @@ int main( void ) TESTCASE( _PDCLIB_strtox_prelim( test3, &sign, &base ) == NULL ); base = 37; TESTCASE( _PDCLIB_strtox_prelim( test3, &sign, &base ) == NULL ); +#endif return TEST_RESULTS; }