connectivity/source/drivers/odbc/ODatabaseMetaData.cxx:1502 is..
1501 ... SQL_ODBC_SQL_CONFORMANCE ...
1502 ... SQL_OSC_CORE || ... SQL_OAC_LEVEL1 || ... SQL_OAC_LEVEL2 ...
and coverity complains that SQL_OAC_LEVEL1 and SQL_OSC_CORE are both 1.
Looking at external/unixODBC/inc/odbc/sqlext.h I see that...
/* SQL_ODBC_SQL_CONFORMANCE values */
#define SQL_OSC_MINIMUM 0x0000
#define SQL_OSC_CORE 0x0001
#define SQL_OSC_EXTENDED 0x0002
while...
/* SQL_ODBC_API_CONFORMANCE values */
#define SQL_OAC_NONE 0x0000
#define SQL_OAC_LEVEL1 0x0001
#define SQL_OAC_LEVEL2 0x0002
i.e. we're randomly comparing a SQL_ODBC_API_CONFORMANCE value
against a result from SQL_ODBC_SQL_CONFORMANCE
so it looks like it should either be...
SQL_OSC_MINIMUM || SQL_OSC_CORE || SQL_OSC_EXTENDED
which would be a change in logic, but perhaps the intent, or
SQL_OSC_CORE || SQL_OSC_EXTENDED
which would keep the status quo (which is 13 years since
26f4169ad38df90493149e8c0b2270eb8e47d541).
Any thoughts on which is preferable?
C.
Context
- coverity#735354 SQL_ODBC_SQL_CONFORMANCE "same on both sides" · Caolán McNamara
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.