mirror of
https://github.com/mdbtools/mdbtools.git
synced 2025-04-05 20:31:00 +08:00
Don't crash when a table can't be read for some reason
This commit is contained in:
parent
463fd0af11
commit
b72ac6b1c0
@ -1337,6 +1337,11 @@ SQLRETURN SQL_API SQLColumns(
|
||||
if (g_ascii_strcasecmp((char*)szTableName, entry->object_name) != 0)
|
||||
continue;
|
||||
table = mdb_read_table(entry);
|
||||
if ( !table )
|
||||
{
|
||||
LogError ("Could not read table '%s'", szTableName);
|
||||
return SQL_ERROR;
|
||||
}
|
||||
mdb_read_columns(table);
|
||||
for (j=0; j<table->num_cols; j++) {
|
||||
col = g_ptr_array_index(table->columns, j);
|
||||
|
Loading…
Reference in New Issue
Block a user