ascii_chk.c

Go to the documentation of this file.
00001 #include "gis.h"
00002 
00003 #define TAB             011
00004 #define SPACE   040
00005 
00016 int G_ascii_check(
00017     char *string )
00018 {
00019     char *ptr1, *ptr2 ;
00020 
00021     ptr1 = string ;
00022     ptr2 = string ;
00023 
00024     while(*ptr1)
00025     {
00026         if ((*ptr1 >= 040) && (*ptr1 <= 0176))
00027             *ptr2++ = *ptr1 ;
00028         else if (*ptr1 == TAB)
00029             *ptr2++ = SPACE ;
00030         ptr1++ ;
00031     }
00032     *ptr2 = 0 ;
00033 
00034     return 0;
00035 }

Generated on Wed Aug 23 17:49:21 2006 for GRASS by  doxygen 1.4.7