Changeset 7205 in orxonox.OLD for branches/std/src/lib/parser/ini_parser/ini_parser.cc
- Timestamp:
- Mar 9, 2006, 8:47:20 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/std/src/lib/parser/ini_parser/ini_parser.cc
r7204 r7205 118 118 // READING IN THE INI-FILE // 119 119 ///////////////////////////// 120 char lineBuffer[PARSELINELENGHT ];121 char buffer[PARSELINELENGHT ];120 char lineBuffer[PARSELINELENGHT+1]; 121 char buffer[PARSELINELENGHT+1]; 122 122 const char* lineBegin; 123 123 char* ptr; … … 129 129 if( (ptr = strchr( lineBuffer, '\n')) != NULL) 130 130 *ptr = 0; 131 else 132 lineBuffer[PARSELINELENGHT] = 0; 131 133 // cut up to the beginning of the line. 132 134 while((*lineBegin == ' ' || *lineBegin == '\t') && lineBegin < lineBuffer + strlen(lineBuffer)) 133 135 ++lineBegin; 136 137 if ( !strcmp( lineBegin, "" ) ) 138 continue; 134 139 135 140 // check if we have a FileComment … … 181 186 --nameEnd; 182 187 nameEnd[1] = '\0'; 183 188 184 189 this->addVar(lineBegin, valueBegin); 185 190 this->setEntryComment();
Note: See TracChangeset
for help on using the changeset viewer.