mridoni / gixsql

GixSQL is an ESQL preprocessor and a series of runtime libraries to enable GnuCOBOL to access PostgreSQL, ODBC, MySQL, Oracle and SQLite databases.
GNU General Public License v3.0
16 stars 8 forks source link

work around sigsegv during preparse #152

Closed GitMensch closed 1 year ago

GitMensch commented 1 year ago

Happens if a new storage starts with a copybook, then with a non 01/77/78 level number (ses related issue).

parse error: FILLER level should start from 01 or 66 or 77 or 88

in which case driver->current_field seems to be empty (and therefore we get a sigsegv at the end of the function); this PR works around that by checking its arguments first