Closed esternin closed 3 years ago
Commit https://github.com/esternin/eXtrema/commit/6a637e36722947de0c60a808ec865a654f93ca09 fixes this bug. Also makes reporting the offending special character string easier to identify, by surrounding it in quotes.
The issue persists under RHEL 7, and Debian on Chromebook, yields
Unhandled unknown exception; terminating the application.
not clear why, the same std::runtime_error( )
works fine under Ubuntu 20.04, but is unhandled under RHEL 7 and under Debian 10.11 (Chromebook). So far only shows up when unexpected whitespace is used inside the string formatting commands, e.g. set xlabel '<degree, theta>'
. As a workaround, trim leading and trailing whitespace before processing each command: https://github.com/esternin/eXtrema/commit/4dcd32f52a2671dc76dcf7cf2906e2e7e6940a7f
reports an invalid special character
" DEGREE"
. This is correct, as the leading space is included, but dumb: we should just get rid of spaces in the special character strings.But this:
causes a crash without an error popping up. So the validity check is not performed, and an invalid string gets assigned to the x-axis label, and graph command dies. This is wrong: error string should be detected and an error message and a graceful recovery should occur.