Skip to content

Commit c2bc4bc

Browse files
committed
oops, 489eb58 alters behavior - thinks 'END-ISO-10303-21;' is invalid EOF
compared keyword with keyword + ';', so of course it failed
1 parent 42ef605 commit c2bc4bc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/cleditor/STEPfile.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1745,12 +1745,12 @@ Severity STEPfile::AppendFile( istream * in, bool useTechCor ) {
17451745
char ch;
17461746
in2->get( ch );
17471747
if( ch != ';' ) {
1748-
std::cerr << __FILE__ << ":" << __LINE__ << " - Expected ';', found '" << c << "'." << std::endl;
1748+
std::cerr << __FILE__ << ":" << __LINE__ << " - Expected ';' at Part 21 EOF, found '" << c << "'." << std::endl;
17491749
}
17501750
}
17511751

1752-
if( ( keywd != END_FILE_DELIM ) || !( in2 -> good() ) ) {
1753-
_error.AppendToUserMsg( END_FILE_DELIM.c_str() );
1752+
if( ( !keywd.compare( 0, keywd.size(), END_FILE_DELIM ) ) || !( in2 -> good() ) ) {
1753+
_error.AppendToUserMsg( END_FILE_DELIM );
17541754
_error.AppendToUserMsg( " missing at end of file.\n" );
17551755
CloseInputFile( in2 );
17561756
return _error.GreaterSeverity( SEVERITY_WARNING );

0 commit comments

Comments
 (0)