Skip to content

Commit

Permalink
generalize QNX fix for test
Browse files Browse the repository at this point in the history
  • Loading branch information
fxing-qnx committed Jan 16, 2025
1 parent 4d11c65 commit ee193bf
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions xmltest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,19 +45,16 @@ bool XMLTest (const char* testString, const char* expected, const char* found, b
printf (" %s\n", testString);
}
else {
const char* expectedString = (expected == NULL) ? "(null)" : expected;
const char* foundString = (found == NULL) ? "(null)" : found;

if ( extraNL ) {
printf( " %s\n", testString );
printf( "%s\n", expected );
printf( "%s\n", found );
printf( "%s\n", expectedString );
printf( "%s\n", foundString );
}
else {
#ifdef __QNX__
const char* expected_qnx = expected == NULL ? "(null)" : expected;
const char* found_qnx = found == NULL ? "(null)" : expected;
printf (" %s [%s][%s]\n", testString, expected_qnx, found_qnx);
#else
printf (" %s [%s][%s]\n", testString, expected, found);
#endif
printf (" %s [%s][%s]\n", testString, expectedString, foundString);
}
}

Expand Down

0 comments on commit ee193bf

Please sign in to comment.