The merge was done manually copying relevant code changes from 1.1.
In particulary merged the patch for CONCPP-94
Also many changes, that fix real possible issues, that was also present in 1.0 and found while
working on 1.1. For example(but not limited to), there were many cases of incorrect
find_first_of std::string method, where find had to be really used.
The fix sets precision 30 for conversion of the double number to its
string representation, requeired for "client side" statement preparing(server
side wasn't affected by the bug). 30 is taked because it's max number of
decimals for decimal column type. This can cause "overflow" errors if
setDouble is used to populate shorter varchar or other types. SOme older
test have been amended to deal with that.
Testframework was fixed to be more informative about where the error
occured(often it printed line where the exception was caught, and for
some tests that is not very helpful.
Fixed couple of compilation warnings.
It choked on const initialization with constexpr
Second possible issue was with
REASON_UNKNOWN in the ClientInfoStatus enum. It clashes with define in
one of Windows headers(Winreg.h). Added undersore prefix to the name.
Also fixed most often warning there.
Additionaly the commit contains some fixes in test faramework and in
tests.
Added missing headers to msi. Headers now installed into include/mariadb
ALl headers have been renamed from .h to .hpp
ConnCpp.hpp renamed to conncpp.hpp(all small letters)
All headers but conncpp.hpp, have been moved to conncpp subdirectory in
include, and in the msi
All exception classes have got explicit (exported from dll on Windows) copyconstructor
decluration, and definition of those constructors in the connector
library. And to stay on the safe side, all other constructors and
destructors definitions have been moved to library side.
Fixed the error, that few exception methods were declared as
dllimported, and defined in the header at the same time.
This includes fixes of various outstanding bugs in CSPS
Made setDouble to accept long double(CONCPP-55)
static_test and driver_test now make one run with default CSPS, and one
with SSPS
Updated README.md with more options info. Changed desription of some
options in DefaultOptions.cpp. Fixed use of autoReconnect and
localSocket
Tests connection credentials can be passed using env variables. All
tests use the same settings for that.
Added the link to the documentation to the README(.md)
Changed in SQLString all size_t to std::size_t(more like for
consictency).
Added npos constant there
Also fixed error in tests, that could make ctest not to notice filed
test suites.
Increased timeouts for some tests(skysql)
Some changes in travis osx script
DatabaseMetaData didn't return correct server version - the call of the
function setting corresponding properties on connection was lost
somewhere.
String utils have been moved to separate unit(util/String.cpp) from
SQLString.cpp, and added to test framework for testing purposes. In
particular few bugs in the split function have been found.
CONCPP-23 and CONCPP-12 are connected, since good part of warnings were
caused by the SQLString class, and its redesign eleminated them among other
things. CONCPP-22 changes could probably be separated from others, but changed files
could also contain changes for other tickets. And still can be fairly
easy separated in case of need.
SQLString now hides internal string implementation and does not provide
the operator for transparent cast to std::string. While const char*
stays in place. Depending on the compiler, a construction
std::string var= <method_call_returning_SQLString>;
may work or may work not.
std::string var(<method_call_returning_SQLString>);
seems to be more portable.
But in the particular case of a blob fetched with
the getString, using the SQLString variable to accept the value is probably the only
choice(because of possible \0 bytes in the string)
Move constructor has been added.
The commit contains too many fixes to remember all of them, really. May
resultset navigation fixes. Crashes, caused by not initializing of some
properties in some classes, etc.
Changed all tests to have configurable via cmake parameters connection
defaults.
cts.sql now uses optional database, and is located in
CMAKE_BINARY_DIR/test