summaryrefslogtreecommitdiff
path: root/include/connectivity
AgeCommit message (Collapse)Author
2024-10-25cid#1633781 Initialization or destruction ordering is unspecifiedCaolán McNamara
and cid#1633780 Initialization or destruction ordering is unspecified cid#1633778 Initialization or destruction ordering is unspecified cid#1633777 Initialization or destruction ordering is unspecified cid#1633776 Initialization or destruction ordering is unspecified Change-Id: I8ae7cbede6df2ad747fe57d0ac2800e1b6a31038 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175576 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-10-22move vcl::DeleteOnDeinit to toolsNoel Grandin
so we can fix a shutdown use-after-free in sot. Change-Id: I32f83bd94627d72d7bee7ea2ebd6ab77a7f78435 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175335 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-09-15Simplify use of connectivity::OConnectionWrapperMike Kaganski
Make it use cppu::WeakComponentImplHelper, because all its derived classes used that template. In the derived classes, switch to use of cppu::ImplInheritanceHelper. That simplifies the hierarchy, and doesn't require to re-implement many basic methods. Change-Id: I40ec05a471af4437098586d20540f9a815677952 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173370 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2024-07-26Refactor ODBC functions code for clarityMike Kaganski
Change-Id: I5f3de97fc178b11c82655f65435c637fdff65e99 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171080 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2024-05-05use [[noreturn]] for these throw helpersCaolán McNamara
Change-Id: Ia50d6f2be91e830201689cc428e55203eeb41eb0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167035 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-03-13reduce symbol visibility in --enable-mergelibs=more modeNoel Grandin
Change-Id: If811c9ec336543227db73c990248b9113846cf2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164657 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-02-19hide more symbolsNoel Grandin
using the bin/find-can-be-private-symbols.py script to find classes with large numbers of exported symbols that can hidden. before exported = 58104 imported = 30810 unused_exports = 35433 after exported = 55094 imported = 31073 unused_exports = 32423 Change-Id: Idd0a70ee3740afd5ca1a86771e0e2ff8090d102d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163456 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-12-30cid#1545421 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1545403 COPY_INSTEAD_OF_MOVE cid#1545397 COPY_INSTEAD_OF_MOVE cid#1545376 COPY_INSTEAD_OF_MOVE cid#1545339 COPY_INSTEAD_OF_MOVE cid#1545288 COPY_INSTEAD_OF_MOVE Change-Id: I0e24a3fc7148d0b7ff8126debe3cddbb4fbdd713 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161453 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-12-24tdf#146619 Recheck include/ with find-unneeded-includes --noexcludeGabor Kelemen
to see if some exclusions became obsolete Change-Id: Id88351f5448511b35994c58c6cb749784da3b45e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156993 Tested-by: Jenkins Reviewed-by: Gabor Kelemen <kelemeng@ubuntu.com>
2023-12-03cid#1546453 COPY_INSTEAD_OF_MOVECaolán McNamara
a sample commit Change-Id: I226569c5d3b066a5c328b67a36c17df57b5a668d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160215 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-09-22tdf#146619 Recheck include/c* with IWYUGabor Kelemen
Change-Id: I0cf6f675483bddf82e7347b484a874c71963bfd7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156984 Tested-by: Jenkins Reviewed-by: Gabor Kelemen <kelemeng@ubuntu.com>
2023-09-01connectivity: add neutral context parserHenry Castro
Signed-off-by: Henry Castro <hcastro@collabora.com> Change-Id: I12b0fe811d141873aaa64af5b6c457051c3356b0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156297 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156424 Tested-by: Jenkins
2023-06-15wrap OSQLParser::s_xLocaleData in vcl::DeleteOnDeinitNoel Grandin
since my adaption of i18npool to use OUStringLiteral, this data structure might get torn down after the i18npool data is has pointers to. Change-Id: If83d232d5bfb003ed4dbfb70d47f707a73d2bcc1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153121 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-04-14loplugin:stringviewparam improvementsNoel Grandin
improve the check by checking for methods that exclude using string_view, rather than checking for methods that __can__ use string_view, which leads to exposing some holes in our o3tl/string_view.hxx coverage. Change-Id: Ic9dd60441c671f502692f9cd2a1bb67301c4b960 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150277 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-04-09use more OUStringToOStringNoel Grandin
which makes it easier to pass around string_view in a few places. Change-Id: Icbbb7f56494986582f1c3272404775bd98031240 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150129 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-03-11osl::Mutex->std::mutex in OSQLParserNoel Grandin
Change-Id: Ibc56fee796914a6dd39970f7a7879d5b5b2c219f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148660 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-03-08osl::Mutex->std::mutex in ParameterWrapperContainerNoel Grandin
Change-Id: I5beb5981d40e970e8bdc68d7bd61f1adb502246d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148440 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-02-22osl::Mutex->std::mutex in OSQLParseNodesContainerNoel Grandin
Change-Id: Ie47589a454799494bc150eec1e135c8948eb7fbf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147420 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-02-16set visibility of classes in mergelib+asan caseAndras Timar
Change-Id: I2eb80d0b3002f174deea0d8657cb0cdbdec5be8f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147144 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2023-02-15new comphelper::SingletonRefNoel Grandin
to replace salhelper::SingletonRef, but using a std::mutex instead of an osl::Mutex Change-Id: Ibf88a3778f47300c08b8ec9ee58ed24eb83aed7b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147046 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-16XUnoTunnel->dynamic_cast in connectivityyNoel Grandin
Change-Id: Ibe5e87a1ef1bdc11451e8fe240d017f1ef60dfe6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145556 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-17cid#1500499 Resource leakCaolán McNamara
the only change should be to the two trailing cases in OSQLParseNode::substituteParameterNames which do seem to leak. The closest I got to triggering the actual code is toggling into sqlview mode of a query but couldn't quite construct a sql statement to trigger it. Change-Id: I320dc4df3b18a18b236c91ee30329c10001c9a08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140081 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-13clang-tidy modernize-pass-by-value in connectivityNoel Grandin
Change-Id: I1f1b609254c7f8cfba14c248167f81b51684d8e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135727 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-20loplugin:passstuffbyrefNoel Grandin
Change-Id: I336fd329b577b6fa141265d8bc7ce67784bd7306 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133210 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-11use more string_viewNoel Grandin
found by tweaking the loplugin:stringview and making it whitelist getLength Change-Id: Ic41cd4e3026d93b70a76fe1279c6de3abbe6b4a0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132820 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-11loplugin:stringview add check for getToken().toInt32Noel Grandin
where we can convert that to o3tl::toInt32(o3tl::getToken( and avoid the heap allocation of a temporary string Change-Id: Ib11c19c6e6cdc0de3e551affd3578d181e292de4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132810 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-02loplugin:stringviewparam convert methods using indexOfNoel Grandin
.. and lastIndexOf, which convert to find and rfind Change-Id: I6c4156cf904774c0d867f85a4c2785dba7593f62 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132445 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-30tdf#143148- Use pragma once in connectivityYomnasalama
Change-Id: If15cf06a986e4bf6ac43b91567a7b2b1aa153d18 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132156 Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2022-03-30tdf#143148: Use pragma once instead of include guardsmostafa-elsharnoby
Change-Id: Iad31b4d3d22519059d340a02868080c829ce7b98 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132158 Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2022-01-14Mysql/MariaDB: tdf#81430 make tables editable (with or without PK)Julien Nabet
Change-Id: I7df464107e692817ef80d887a4addea618d6cc72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128356 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-12-15Recheck include/[a-d]* with IWYUGabor Kelemen
See tdf#42949 for motivation Change-Id: I42475b8e75951d5dcae2fe6b0ad0bca64441e7f5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126837 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-11-27use more OInterfaceContainerHelper3 in connectivity::sdbcx::OCollectionNoel Grandin
Change-Id: Idf3313b374eae05c4a65c101e1e7ce91c743b420 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125928 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-27use more OInterfaceContainerHelper3 in dbtools::ParameterManagerNoel Grandin
Change-Id: Ice607fb67468484e98c94e4f41c3e249639e1edb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125922 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-24loplugin:stringliteraldefine in connectivityNoel Grandin
Change-Id: I6b2528c684fe56a114959a1d26101a882eee2106 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125759 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-23remove ORowSetValue implicit conversion methodsNoel Grandin
in favour of the existing get*() methods. The get*() methods 0 or false or empty in the case of "null", which is exactly the same behaviour as the conversion methods. These implicit conversion methods cause lookup problems when combined with some upcoming OUString changes. And the code looks cleaner this way too, and has less magic when calling methods. Change-Id: Ieb4756bf693e83b996a32667fc1b955f89193496 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125690 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-06loplugin:moveparam in connectivityNoel Grandin
Change-Id: Iaf3a64effb69fd82c6303d8fa75723ccc5ced543 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123183 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-27pass the column names in as an external argumentCaolán McNamara
Change-Id: I14ab9e6de0a704076a1c632b6b33aaeabdfc23d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122660 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-27split getUniqueColumnNameCaolán McNamara
Change-Id: Ibcac473463c02e7ce6f853ac2dcdf953c13c14e7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122659 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-27appendColumns is always called with m_aSelectColumns as 1st argCaolán McNamara
Change-Id: I791c0eef1fda97d21ba9efb170ef226c9a495eed Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122658 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-27setSelectColumnName is always called with m_aSelectColumns as 1st argCaolán McNamara
Change-Id: If86c4f48ed7eb6860f461fe905c0628cb9b73043 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122657 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-24make SQLExceptionInfo utilities available for external useCaolán McNamara
Change-Id: I6561fa433f6619d8de97983fa962f874cbf5b536 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122570 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-23leaks of OCollection in dbase importCaolán McNamara
presumably since... commit 5c7b954935369cbbd22a6f43be63ac7c0ddbbfdc Date: Mon Jan 29 13:28:44 2018 +0200 loplugin:useuniqueptr in OTable OCollection has a unique and nonstandard acquire/release which forwards to a parent cppu::OWeakObject. So when it would appear to a casual observer, who assumes that it has an internal refcount, that its refcount would drop to zero and then get auto-deleted, nothing of the kind occurs. Change-Id: Ic292663a61b4d7dbf7636be7ad4c00aed0b5a7fa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122528 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-06-19loplugin:finalclassesNoel Grandin
improve the plugin to detect more cases. I only apply the new final changes to classes in /include here. Which reveals that RoadmapWizard::getPageController( TabPage* _pCurrentPage ) will always return nullptr Also needed to sprinkle some SAL_DLLPUBLIC_TEMPLATE around to workaround Visual Studio linking problems. Change-Id: Iadb7d46a9e0e73dabce562375ca013c0fea6690c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117365 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-02throw() -> noexcept, part 2/3: Automatic loplugin:noexcept rewriteStephan Bergmann
Change-Id: I076f16d0536b534abf0ced4d76051eadb4c0e033 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114949 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-02-22loplugin:refcounting in connectivityNoel
Change-Id: Iff2f096e7ee00d9cb29d47462dd7e1963c6b06e0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111302 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-29loplugin:stringviewparam extend to new..Noel
O[U]StringBuffer methods Change-Id: I0ffbc33d54ae7c98b5652434f3370ee4f819f6f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110090 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-11Adapt the remaining OUString functions to std string_viewStephan Bergmann
...for LIBO_INTERNAL_ONLY. These had been missed by 1b43cceaea2084a0489db68cd0113508f34b6643 "Make many OUString functions take std::u16string_view parameters" because they did not match the multi-overload pattern that was addressed there, but they nevertheless benefit from being changed just as well (witness e.g. the various resulting changes from copy() to subView()). This showed a conversion from OStringChar to std::string_view to be missing (while the corresponding conversion form OUStringChar to std::u16string_view was already present). The improvement to loplugin:stringadd became necessary to fix > [CPT] compilerplugins/clang/test/stringadd.cxx > error: 'error' diagnostics expected but not seen: > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 43 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:42): simplify by merging with the preceding assignment [loplugin:stringadd] > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 61 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:60): simplify by merging with the preceding assignment [loplugin:stringadd] > 2 errors generated. Change-Id: Ie40de0616a66e60e289c1af0ca60aed6f9ecc279 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107602 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-09Fix loplugin:stringviewparam handling of comparison operatorsStephan Bergmann
Change-Id: I58456efb9588b544d998ac6a4c27d55457280742 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107510 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-11-24loplugin:stringviewparam extend to comparison operatorsNoel
which means that some call sites have to change to use unicode string literals i.e. u"foo" instead of "foo" Change-Id: Ie51c3adf56d343dd1d1710777f9d2a43ee66221c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106125 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>