| 102 | */ |
| 103 | |
| 104 | static int EatWhitespace( FILE *InFile ) |
| 105 | /* ------------------------------------------------------------------------ ** |
| 106 | * Scan past whitespace (see ctype(3C)) and return the first non-whitespace |
| 107 | * character, or newline, or EOF. |
| 108 | * |
| 109 | * Input: InFile - Input source. |
| 110 | * |
| 111 | * Output: The next non-whitespace character in the input stream. |
| 112 | * |
| 113 | * Notes: Because the config files use a line-oriented grammar, we |
| 114 | * explicitly exclude the newline character from the list of |
| 115 | * whitespace characters. |
| 116 | * - Note that both EOF (-1) and the nul character ('\0') are |
| 117 | * considered end-of-file markers. |
| 118 | * |
| 119 | * ------------------------------------------------------------------------ ** |
| 120 | */ |
| 121 | { |
| 122 | int c; |
| 123 | |
| 124 | for( c = getc( InFile ); isspace( c ) && ('\n' != c); c = getc( InFile ) ) |
| 125 | ; |
| 126 | return( c ); |
| 127 | } /* EatWhitespace */ |
| 128 | |
| 129 | static int EatComment( FILE *InFile ) |
| 130 | /* ------------------------------------------------------------------------ ** |