summaryrefslogtreecommitdiff
path: root/connectivity
AgeCommit message (Collapse)Author
2018-09-17New loplugin:externalStephan Bergmann
...warning about (for now only) functions and variables with external linkage that likely don't need it. The problems with moving entities into unnamed namespacs and breaking ADL (as alluded to in comments in compilerplugins/clang/external.cxx) are illustrated by the fact that while struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } returns 1, both moving just the struct S2 into an nunnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { namespace { struct S2: S1 { int f() { return 1; } }; } int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } as well as moving just the function f overload into an unnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; namespace { int f(S2 s) { return s.f(); } } } int main() { return f(N::S2()); } would each change the program to return 0 instead. Change-Id: I4d09f7ac5e8f9bcd6e6bde4712608444b642265c Reviewed-on: https://gerrit.libreoffice.org/60539 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-09-14loplugin:simplifyconstruct (macOS)Stephan Bergmann
Change-Id: I460732b2ea9e7366943162bef8f4fced5f975e95 Reviewed-on: https://gerrit.libreoffice.org/60466 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-09-13mysqlc: fix XPreparedStatement::setTimestampTamas Bunth
Change-Id: Ia0d0290517fdebd9a7700d52fa0e86de0e958b2d Reviewed-on: https://gerrit.libreoffice.org/60406 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-09-13mysqlc: prep stmt: check if cursor out of rangeTamas Bunth
Change-Id: I81307c6e45220081c39ddd7d1672457202bbc517 Reviewed-on: https://gerrit.libreoffice.org/60404 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-09-13mysqlc: Fix XResultSet::absolute and previousTamas Bunth
We need to update the actual row position after using absolute or previous. Change-Id: Ie85f9679b7a06649a88ac8ee08436bf7f4a58a22 Reviewed-on: https://gerrit.libreoffice.org/60328 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-09-13tdf#42949 Fix IWYU warnings in include/ucbhelper/*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I7bfeef47abaf94cfb355db95c0fdb928ce36c0a6 Reviewed-on: https://gerrit.libreoffice.org/60232 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-09-11-Werror,-Wunused-macros (clang-cl)Stephan Bergmann
Change-Id: I53b736d8b243f6e9da09856e0729b8702c4167d2 Reviewed-on: https://gerrit.libreoffice.org/60323 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-09-11loplugin:unusedmethodsNoel Grandin
Change-Id: I34009aabf0befb346470b5c0d96ad8fc476b7c4e Reviewed-on: https://gerrit.libreoffice.org/60300 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-11loplugin:constantparamNoel Grandin
Change-Id: Ia11bf93768d5f722b7fe62df15f24809cb7e7f04 Reviewed-on: https://gerrit.libreoffice.org/60280 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-10tdf#42949 Fix IWYU warnings in include/cppuhelper/*Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ib420e9216b8313f5ed7634ec375e39ceb741fd45 Reviewed-on: https://gerrit.libreoffice.org/59297 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-09-08Fix typosAndrea Gelmini
Change-Id: I75692373028a64ba71899a4fd8c240fa4f2f1c02 Reviewed-on: https://gerrit.libreoffice.org/60172 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2018-09-07mysqlc: ensure cursor is not out of rangeTamas Bunth
when calling getXXX() methods of a simple result set. Change-Id: I9e018385bb73468ea520b03275232c0982cbcba0 Reviewed-on: https://gerrit.libreoffice.org/60095 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-09-06loplugin:simplifyconstruct in canvas..cuiNoel Grandin
Change-Id: I02eba1df117a9d0df42bcac13c3251cb4fa6da14 Reviewed-on: https://gerrit.libreoffice.org/60074 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-06loplugin:useuniqueptr in OResultSetMetaDataNoel Grandin
Change-Id: I74a12381a222fb3b394176db41cb9d6a9091d5a3 Reviewed-on: https://gerrit.libreoffice.org/60052 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-01mysqlc: implement beforeFirst and fix findColumnTamas Bunth
Change-Id: I9a12ef6c61b83f588be89ed9aff301d570155d74 Reviewed-on: https://gerrit.libreoffice.org/59880 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-31tdf#119615 Ownership of m_aFields is..Tamas Bunth
.. on Mariadb side Change-Id: Id65487191c29f7af1a171c06345034d1dc5b20ec Reviewed-on: https://gerrit.libreoffice.org/59856 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-31mysqlc: implement getImpotedKeysTamas Bunth
Change-Id: Ic819389000b5b31de69bece6b280cf89f93db948 Reviewed-on: https://gerrit.libreoffice.org/59851 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-30Combine mysqlc and connectivity.mysqlc log areasStephan Bergmann
Change-Id: I2d13401dc21548018235bab715d54eb3ae81b51b Reviewed-on: https://gerrit.libreoffice.org/59807 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-08-30Revert "On macOS Library_mysqlc needs _iconv{,_close,_open}"Michael Stahl
This reverts commit a191075ee1bd103a57c935e47026337a5e2340e9. This fix was superceded by commit 13a05eec7377c013d9c13deeee6473a9e863c897 which is better abstracted. Change-Id: I3b8ba735d279a50f5548a26fcc8fa6f790b2ea42
2018-08-30Translate German commentsJohnny_M
Change-Id: I8e3b98e1ddc3f4f9826aa14383908d6b77f4827a Reviewed-on: https://gerrit.libreoffice.org/59592 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-08-29mysqlc: Add library to log areas and put someTamas Bunth
warnings into databasemetadata Change-Id: I4c2841e9174e738fff6b8627f8860588c7838c49 Reviewed-on: https://gerrit.libreoffice.org/59755 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-29Replace find_if with proper quantifier algorithmsArkadiy Illarionov
Change-Id: Icc820a47ac891c358883f9c01224f676c58fdd11 Reviewed-on: https://gerrit.libreoffice.org/59744 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-29new loplugin:oustringbufferNoel Grandin
look for places where we are appending the temporary result of adding strings together, to an OUStringBuffer, where we could rather call append repeatedly and avoid the temporary creation Change-Id: I481435124291ac7fb54b91a78344a9fe5b379a82 Reviewed-on: https://gerrit.libreoffice.org/59708 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-29loplugin:constantparam (1)Noel Grandin
Change-Id: I25077e391ecca1b678062d261a83d88daadf0a58 Reviewed-on: https://gerrit.libreoffice.org/59701 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-28mysqlc: registry xml: install driverTamas Bunth
Change-Id: I864302cc7ba8f27300e4bf0dd3d8a6cc1896da4b Reviewed-on: https://gerrit.libreoffice.org/59698 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-28SYSTEM_MYSQL_CPPCONN is never definedStephan Bergmann
...since 5061663ce052087c6d5d0910d6f99358e26dbbd1 "drop unnecessary SYSTEM_MYSQL_CONNECTOR_CPP" Change-Id: I2023baf04dfb050833a0032367fc2dc2cfdb9d92 Reviewed-on: https://gerrit.libreoffice.org/59670 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-08-27coverity#1438784 Uninitialized pointer fieldCaolán McNamara
Change-Id: Ic8bc7423765f8610d92ca3ced4c52d4838b7699a Reviewed-on: https://gerrit.libreoffice.org/59653 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-27coverity#1438783 Unchecked return valueCaolán McNamara
Change-Id: Ice56d317087dd24d2eef27f2ace5fdf9f4da946d Reviewed-on: https://gerrit.libreoffice.org/59654 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-27coverity#1438785 Uninitialized pointer fieldCaolán McNamara
Change-Id: I62c26622992447fd0dbc5fa857cb7231e9d00154 Reviewed-on: https://gerrit.libreoffice.org/59652 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-27mysqlc: fix registry configurationTamas Bunth
Change-Id: Iefe1446e5f28471c6cafd256b29612c2457e42fc Reviewed-on: https://gerrit.libreoffice.org/59640 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-27mysqlc: Fix issue by freeing result setsTamas Bunth
Change-Id: I8a5f886306e028f06243768376b2a6c55df6063c Reviewed-on: https://gerrit.libreoffice.org/59210 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-27-Werror,-Wunused-private-fieldStephan Bergmann
Change-Id: I8c71fe9a5ae0d228313b6b66752ee93aae72f539
2018-08-26drop unnecessary SYSTEM_MYSQL_CONNECTOR_CPPCaolán McNamara
Change-Id: I41cfbf41247270d29e08e5125adc05aac198b175 Reviewed-on: https://gerrit.libreoffice.org/59608 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-26presumably should be mysqlc hereCaolán McNamara
Change-Id: I328cb639cf1e190e745aa20e0f83b0e3e4fd2f60 Reviewed-on: https://gerrit.libreoffice.org/59606 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-26CPPCONN_LIB now unusedCaolán McNamara
since commit 26b40fcfc67480e75bd9959b0c5cb9db10fdf6a1 Author: Tamas Bunth <tamas.bunth@collabora.co.uk> Date: Thu Aug 16 16:35:17 2018 +0200 Moving mysqlc into connectivity as a library Change-Id: Iafc4fb685d8f7b97f8be83dbf26945f9af976f1a Reviewed-on: https://gerrit.libreoffice.org/59604 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-24Fix typosAndrea Gelmini
Change-Id: Ie6e3f3edabcd1ef9b44aefeb81ea84ca28654606 Reviewed-on: https://gerrit.libreoffice.org/59578 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-08-24Moving mysqlc into connectivity as a libraryTamas Bunth
Additionally I erased the remains of the old mysql C++ connector. Also update the code where the clang plugins were unhappy after moving the mysqlc module. Remove mysql-cpp-connector external. Change-Id: I771cc7afacf5012fc349afb6b36828fb0fee5a66 Reviewed-on: https://gerrit.libreoffice.org/59200 Tested-by: Jenkins Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-08-20Simplify containers iterations, tdf#96099 follow-upArkadiy Illarionov
Use range-based loop or replace with std::any_of, std::find and std::find_if where applicable. Change-Id: I2f80788c49d56094c29b102eb96a7a7c079567c6 Reviewed-on: https://gerrit.libreoffice.org/59143 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-19Translate German commentsJohnny_M
Change-Id: I1a4e41ccd3e3eb829419c45edd0417776a73c3ae Reviewed-on: https://gerrit.libreoffice.org/59285 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-08-17loplugin:useuniqueptr in connectivity/fileNoel Grandin
Change-Id: I39c3b164c78a10f7a499974db3690d062dc59753 Reviewed-on: https://gerrit.libreoffice.org/59223 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-16Fix typo: s/an other/another/gAndrea Gelmini
Change-Id: I203c546cfca841e7853282267190e20b60919add Reviewed-on: https://gerrit.libreoffice.org/59098 Tested-by: Jenkins Reviewed-by: Jens Carl <j.carl43@gmx.de>
2018-08-15pgsql-sdbc: better debug messageLionel Elie Mamane
Change-Id: I28a218b39be6436bac3cbdaa9dd25385c7964d09
2018-08-14create appendCopy method in OUStringBufferNoel Grandin
so we can avoid temporary copies when appending a substring of an OUString to the buffer. I would have preferred to call the method just "append" but that results in ambiguous method errors when the callsite is something like sal_Int32 n; OUStringBuffer s; s.append(n, 10); I'm not sure why Change-Id: I6b5b6641fcb5b26ce2269f89ef06e03c0b6aa76f Reviewed-on: https://gerrit.libreoffice.org/58666 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-13Translate German variable namesJohnny_M
frei -> free Change-Id: Ib402bd7829a2ac519350ad1294510adefc872514 Reviewed-on: https://gerrit.libreoffice.org/58874 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-08-05coverity#1438225 Improper use of negative valueCaolán McNamara
and coverity#1438221 Argument cannot be negative coverity#1438213 Argument cannot be negative coverity#1438227 Argument cannot be negative coverity#1438223 Argument cannot be negative coverity#1438222 Argument cannot be negative coverity#1438215 Improper use of negative value coverity#1438220 Improper use of negative value coverity#1438217 Improper use of negative value Change-Id: I398ae9901b27f6b65f03aad03638939b5880a671 Reviewed-on: https://gerrit.libreoffice.org/58626 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-08-01loplugin:returnconstant in connectivityNoel Grandin
Change-Id: I291bebbd644095d6632841abe56c4f28b84e228d Reviewed-on: https://gerrit.libreoffice.org/58427 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-29replace double checked locking patternsJochen Nitschke
with thread safe static initialization Change-Id: I7b102e8a6aec64b0795f5fa915276ffc1f568d0a Reviewed-on: https://gerrit.libreoffice.org/58288 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-29remove unused variableJochen Nitschke
Change-Id: I22454ef597e679439f6c5b71866022c90823a690 Reviewed-on: https://gerrit.libreoffice.org/58260 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-28Restore the accidentally overwritten array value in ODatabaseMetaDataMuhammet Kara
Seems like there was a copy/paste/programming error in baaa43446f5661177b4900f260bba313883c4032 Change-Id: I9cb9ee816f274457d6632064bdbff926565f906d Reviewed-on: https://gerrit.libreoffice.org/57793 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@pardus.org.tr>
2018-07-28loplugin:stringloop basctl,chart2,connectivityNoel Grandin
Change-Id: I21353dace60705d55b3d70f1e0bc610d55b84d63 Reviewed-on: https://gerrit.libreoffice.org/58210 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>