Age | Commit message (Collapse) | Author |
|
(i.e., all members of the typedef'ed struct oslPipeBuffer are unused because the
typedef'ed struct itself is unused ever since at least
9399c662f36c385b0c705eb34e636a9aec450282 "initial import")
Change-Id: If14ea3b0a1c0bc02b6949fead17513cda8107601
Reviewed-on: https://gerrit.libreoffice.org/84859
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...that had been added by accident with 55e596956e56b175ab17b682e7c8ac7daeb9289a
"loplugin:external (clang-cl)"
Change-Id: Ieff93c825632d68adb621d8f646ff8abb72b5452
Reviewed-on: https://gerrit.libreoffice.org/84599
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...plus loplugin:consttobool and loplugin:fakebool fallout
Change-Id: Ie3d8121815c080b13bea6d9deca1eb138ca56138
Reviewed-on: https://gerrit.libreoffice.org/84515
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...after that file got re-enabled for Windows builds recently
Change-Id: I67c9e1676344d3754293595ec5a3c6093c0959c1
Reviewed-on: https://gerrit.libreoffice.org/84510
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
<http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1423r3.html> "char8_t
backward compatibility remediation", as implemented now by <https://gcc.gnu.org/
git/?p=gcc.git;a=commit;h=0c5b35933e5b150df0ab487efb2f11ef5685f713> "libstdc++:
P1423R3 char8_t remediation (2/4)" for -std=c++2a, deletes operator << overloads
that would print an integer rather than a (presumably expected) character.
But for simplicity (and to avoid issues with non-printing characters), keep
printing an integer here.
Change-Id: I751b99ee32d418eb488131ffa130d6f7d6d38dc7
Reviewed-on: https://gerrit.libreoffice.org/84348
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
this is a very very useful warning when libraries fail to load
Change-Id: I09bf64f6c65f285d6ab41f988b255a4842233428
Reviewed-on: https://gerrit.libreoffice.org/84314
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Id28d593d94fc176194871db32c1c5a287b98a26a
Reviewed-on: https://gerrit.libreoffice.org/84319
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
The open_004 unit test fails on Windows with E_NOENT. I think the
assert is correct, and it's better change the ERROR_DIRECTORY
mapping, as FindFirstFileW returns ERROR_PATH_NOT_FOUND, if the
path doesn't exists at all.
The description of that error code in the MS API docs is "The
directory name is invalid.". And obviously there is no way to
tell, if this is actually a better mapping.
Change-Id: Id122ce39e90f3562e70c96a06752e5b32ed55b41
Reviewed-on: https://gerrit.libreoffice.org/84070
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
This just disables open::open_004 test on Windows, as this returns
E_NOENT on Windows, but I think the assert is correct. There is
also test-getsystempathfromfileurl.cxx, which seems to overlap?
The test now uses osl::FileBase::getTempDirURL to find the system
temporary directory, insted of hardcoded defaults.
This also includes reverts the following commits:
* "remove unused Exist from oslCheckMode enum"
commit 4ca9e8fa3a040c18221c947a651469a89029282e.
* "CppunitTest_sal_osl_file fails on Windows"
commit 4603028bc4e2cdacd32da073a82a42ba1fc549a8
Change-Id: Ib7fc4c13f8159a240d4e20c26f61d84204e4261b
Reviewed-on: https://gerrit.libreoffice.org/83901
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
No need for this when we have a compile-time distinction now anyway.
Change-Id: Ic86c8cce38a86635ea3efb4229c08f63059c9ee6
Reviewed-on: https://gerrit.libreoffice.org/83719
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jenkins
|
|
Change-Id: I8901780fa29c6d27bb53e44b07d95259b5bd02df
Reviewed-on: https://gerrit.libreoffice.org/83920
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit f3af7708e3535d3171832aa2308d1e7f6193def4)
Reviewed-on: https://gerrit.libreoffice.org/84189
Tested-by: Jenkins
|
|
Change-Id: I5e8214efbf32a5bc43f002ef244826b9b899c692
Reviewed-on: https://gerrit.libreoffice.org/84071
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
From all I could find, a single (back-)slash file URI is fine as
a local file path.
Change-Id: I75e95c809894cdef88f708d0477cb98eb114a107
Reviewed-on: https://gerrit.libreoffice.org/83837
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
|
|
Change-Id: I362d277d3ad2b2604107ddb6928c76ebec94efc3
Reviewed-on: https://gerrit.libreoffice.org/83868
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
(to silence upcoming loplugin:unusedmember)
Change-Id: I86e340e6ade043e020609f0f4da58ba94be6ab1b
Reviewed-on: https://gerrit.libreoffice.org/83817
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Iab2231e90e55c7e583a2fafd08469ee01b02ce82
Reviewed-on: https://gerrit.libreoffice.org/83767
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I81fea38cd737a8be74e6ece333ca37cc434a1c33
Reviewed-on: https://gerrit.libreoffice.org/83765
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
add attribute markup
Change-Id: I8d70513ae3e7abf80368016343f69060f197eae0
Reviewed-on: https://gerrit.libreoffice.org/83586
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I77e28f02516ab25ff6680970dc13d52cfa90eac1
Reviewed-on: https://gerrit.libreoffice.org/83620
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
...following up on 314f15bff08b76bf96acf99141776ef64d2f1355 "Extend
loplugin:external to warn about enums".
Cases where free functions were moved into an unnamed namespace along with a
class, to not break ADL, are in:
filter/source/svg/svgexport.cxx
sc/source/filter/excel/xelink.cxx
sc/source/filter/excel/xilink.cxx
svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx
All other free functions mentioning moved classes appear to be harmless and not
give rise to (silent, even) ADL breakage. (One remaining TODO in
compilerplugins/clang/external.cxx is that derived classes are not covered by
computeAffectedTypes, even though they could also be affected by ADL-breakage---
but don't seem to be in any acutal case across the code base.)
For friend declarations using elaborate type specifiers, like
class C1 {};
class C2 { friend class C1; };
* If C2 (but not C1) is moved into an unnamed namespace, the friend declaration
must be changed to not use an elaborate type specifier (i.e., "friend C1;"; see
C++17 [namespace.memdef]/3: "If the name in a friend declaration is neither
qualified nor a template-id and the declaration is a function or an
elaborated-type-specifier, the lookup to determine whether the entity has been
previously declared shall not consider any scopes outside the innermost
enclosing namespace.")
* If C1 (but not C2) is moved into an unnamed namespace, the friend declaration
must be changed too, see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71882>
"elaborated-type-specifier friend not looked up in unnamed namespace".
Apart from that, to keep changes simple and mostly mechanical (which should help
avoid regressions), out-of-line definitions of class members have been left in
the enclosing (named) namespace. But explicit specializations of class
templates had to be moved into the unnamed namespace to appease
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92598> "explicit specialization of
template from unnamed namespace using unqualified-id in enclosing namespace".
Also, accompanying declarations (of e.g. typedefs or static variables) that
could arguably be moved into the unnamed namespace too have been left alone.
And in some cases, mention of affected types in blacklists in other loplugins
needed to be adapted.
And sc/qa/unit/mark_test.cxx uses a hack of including other .cxx, one of which
is sc/source/core/data/segmenttree.cxx where e.g. ScFlatUInt16SegmentsImpl is
not moved into an unnamed namespace (because it is declared in
sc/inc/segmenttree.hxx), but its base ScFlatSegmentsImpl is. GCC warns about
such combinations with enabled-by-default -Wsubobject-linkage, but "The compiler
doesn’t give this warning for types defined in the main .C file, as those are
unlikely to have multiple definitions."
(<https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc/Warning-Options.html>) The
warned-about classes also don't have multiple definitions in the given test, so
disable the warning when including the .cxx.
Change-Id: Ib694094c0d8168be68f8fe90dfd0acbb66a3f1e4
Reviewed-on: https://gerrit.libreoffice.org/83239
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ibf97a830932d3f153b99031abc8c4a00b54cedab
Reviewed-on: https://gerrit.libreoffice.org/83265
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Jenkins
|
|
...plus follow-up loplugin:implicitboolconversion and loplugin:redundantcast
Change-Id: I9fc9c5cb46fbb50da87ff80af64cb0dfda3e5f90
Reviewed-on: https://gerrit.libreoffice.org/83207
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
(the use of `BOOL gotACP` in osl_getThreadTextEncoding was already safe in the
past, converting from 16-bit HIWORD to 32-bit BOOL and then using operator!)
Change-Id: Ic5019093b350b968edfcf0878126671285891502
Reviewed-on: https://gerrit.libreoffice.org/83210
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
code reads a .ui file to show a menu to edit/delete that pagebreak. That
file was not packaged in the Android viewer and causes an exception that
is not handled and ultimately results in a crash.
Change-Id: Ie73d886daf9202ba12e1b5a241bc7b6d184ae770
Reviewed-on: https://gerrit.libreoffice.org/83104
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
|
|
To mitigate the dangers of silently breaking ADL when moving enums into unnamed
namespaces (see the commit message of 206b5b2661be37efdff3c6aedb6f248c4636be79
"New loplugin:external"), note all functions that are affected. (The plan is to
extend loplugin:external further to also warn about classes and class templates,
and the code to identify affected functions already takes that into account, so
some parts of that code are not actually relevant for enums.)
But it appears that none of the functions that are actually affected by the
changes in this commit relied on being found through ADL, so no adaptions were
necessary for them.
(clang::DeclContext::collectAllContexts is non-const, which recursively means
that External's Visit... functions must take non-const Decl*. Which required
compilerplugins/clang/sharedvisitor/analyzer.cxx to be generalized to support
such Visit... functions with non-const Decl* parameters.)
Change-Id: Ia215291402bf850d43defdab3cff4db5b270d1bd
Reviewed-on: https://gerrit.libreoffice.org/83001
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
as found by <https://ci.libreoffice.org/job/lo_tb_random_config_linux/2039/>
Change-Id: Ie698b7905bd2f25e74791f91f586479d1fc473dc
Reviewed-on: https://gerrit.libreoffice.org/82488
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ib91d77c578aa21af02beaf299d16b5d8c2942f00
Reviewed-on: https://gerrit.libreoffice.org/82447
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
by 10%, by avoiding an OUString construction in a hot path
through
XMLTextColumnContext_Impl::XMLTextColumnContext_Impl
-> sax::Convert::convertNumber
Also changed XMLTextAnimationStepPropertyHdl::importXML
to take advantage of the modified convertNumber passing
convention.
Change-Id: I4e5503dbb094c88a09af8b6dc8c22b6c53f9eb75
Reviewed-on: https://gerrit.libreoffice.org/81726
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
if one side of the expression is a compile-time-constant, we don't need
to worry about side-effects on the other side
Change-Id: Iee71ea51b327ef244bf39f128f921ac325d74e2b
Reviewed-on: https://gerrit.libreoffice.org/81589
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
same as b89187aad86e2be000d2f4c9c380a95bf8430c2e "Simplify forced memory reads"
in sal/osl/unx/file.cxx
Change-Id: I31edbc72f88895e148609498d367a50e38723b11
Reviewed-on: https://gerrit.libreoffice.org/81408
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...which had been dropped by 0f874472c672175135520101837ff0c9d4701d7f "size some
stringbuffer to prevent re-alloc", presumably by accident
Change-Id: I3b84e743c1adcdd8518114810dcee5c3f12c4290
Reviewed-on: https://gerrit.libreoffice.org/81388
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
found by the simple expidient of putting asserts in
the resize routine. Where an explicit const size is used,
I started with 32 and kept doubling until that site
did not need resizing anymore.
Change-Id: I998787edc940d0a3ba23b5ac37131ab9ecd300f4
Reviewed-on: https://gerrit.libreoffice.org/81138
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
(At least MSVC++ 14.14, aka Visual Studio 2017 version 15.7, apparently requires
`"\xDFFF"` to be written with a `u` prefix in the concatenated string literal
u"\xD800" "\U000103FF" "\xDFFF" "A"
to avoid "error C2022: '57343': too big for character", so prefix all the
individual string literals in such concatenations, even if that should be
redundant.)
Change-Id: Ief69e6c7ae71fe2c4c9c56c38fab0bc782ceb82c
Reviewed-on: https://gerrit.libreoffice.org/81142
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I3e5efb9be471814b5dabf501feb93a65e9b5bcd3
Reviewed-on: https://gerrit.libreoffice.org/81022
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Replace them with default initialization or calloc
Change-Id: I747f53c2ced2d0473fd5a5ede4f8520a0633dcc1
Reviewed-on: https://gerrit.libreoffice.org/80805
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
It started out as a wrapper around character literals, but has by now become a
wrapper around arbitrary single characters. Besides updating the documentation,
this change is a mechanical
for i in $(git grep -Fl OUStringLiteral1); do sed -i -e s/OUStringLiteral1/OUStringChar/g "$i"; done
Change-Id: I1b9eaa4b3fbc9025ce4a4bffea3db1c16188b76f
Reviewed-on: https://gerrit.libreoffice.org/80892
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ifbdb3e41eae665f7dcaf5301aaba2b6e4662cf48
Reviewed-on: https://gerrit.libreoffice.org/80855
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
look for OUStringBuffer append sequences that can be turned
into creating an OUString with + operations
Change-Id: Ica840dc096000307b4a105fb4d9ec7588a15ade6
Reviewed-on: https://gerrit.libreoffice.org/80809
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
...(which got introduced with 9b5dad13b56bdde7c40970351af3da3a2c3c9350
"loplugin:stringadd look for unnecessary temporaries", and had reportedly
broken CppunitTest_sc_ucalc on tml's Windows build by hitting the
"strlen( str ) == N - 1" assert at include/rtl/string.hxx:1867), by introducing
rtl::OStringView (and rtl::OUStringView, for consistency).
Change-Id: I766b600274302ded66a6bffc91be189b20ed1ac3
Reviewed-on: https://gerrit.libreoffice.org/80778
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...to find matches of
... << s.getStr()
(for the rtl string classes) that can be written as just
... << s
Some notes:
* The OUStringToOString(..., RTL_TEXTENCODING_UTF8) is left explicit in
desktop/source/app/crashreport.cxx (even though that would also be done
internally by the "<< OUString" operator) to clarify that these values are
written out as UTF-8 (and not as what that operator << happens to use, which
just also happens to be UTF-8).
* OUSTRING_TO_CSTR (include/oox/helper/helper.hxx) is no longer used now.
* Just don't bother to use osl_getThreadTextEncoding() in the SAL_WARN in
lingucomponent/source/hyphenator/hyphen/hyphenimp.cxx.
* The toUtf8() in the SAL_DEBUG in pyuno/source/module/pyuno_module.cxx can just
go, too.
Change-Id: I4602f0379ef816bff310f1e51b57c56b7e3f0136
Reviewed-on: https://gerrit.libreoffice.org/80762
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
which defeat the *StringConcat optimisation.
Also make StringConcat conversions treat a nullptr as an empty string,
to match the O*String(char*) constructors.
Change-Id: If45f5b4b6a535c97bfeeacd9ec472a7603a52e5b
Reviewed-on: https://gerrit.libreoffice.org/80724
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
so we can construct efficient expressions when we have pointers to
unicode data
Also lightly reformat a couple of the older helpers to make it easier to
compare the different helpers.
Change-Id: Ib8a4227714e9218512b6871d3285e4e2703bec3b
Reviewed-on: https://gerrit.libreoffice.org/80639
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I5803aa2498654c579f9fe6293e5204aa63edd589
Reviewed-on: https://gerrit.libreoffice.org/80607
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Icfa358476db3166c29e893c09ec943aa3c38dba3
Reviewed-on: https://gerrit.libreoffice.org/80520
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I6febe3d48fc9018b373a940d88d2afeefad7502c
Reviewed-on: https://gerrit.libreoffice.org/80355
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: Ib8b2bc1c5f7b27a646036ce23cae2b6a06edd038
Reviewed-on: https://gerrit.libreoffice.org/79922
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I08da288a88c2bce1d4250ec77f17bd483e6bc09c
Reviewed-on: https://gerrit.libreoffice.org/79911
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I1f8b626ae99bca6e31e7c4aa9c8a1fc016b76e5c
Reviewed-on: https://gerrit.libreoffice.org/79890
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Apply the constmethod plugin, but only to accessor-type methods, e.g.
IsFoo(), GetBar(), etc, where we can be sure of that
constifying is a reasonable thing to do.
Change-Id: Ibc97f5f359a0992dd1ce2d66f0189f8a0a43d98a
Reviewed-on: https://gerrit.libreoffice.org/74269
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
When I did the fast string concatenation, I didn't add any support
for number(), which simply returned a O(U)String, and so it did
the extra allocation/deallocation, although that could be avoided.
In order to support this, number() now returns a special temporary
return type, similarly to O(U)StringConcat, which allows delaying
the concatenation the same way.
Also similarly, the change of the return type in some cases requires
explicit cast to the actual string type. Usage of OString::getStr()
is so extensive in the codebase that I actually added it to the helper
class, after that it's only relatively few cases.
Change-Id: Iba6e158010e1e458089698c426803052b6f46031
Reviewed-on: https://gerrit.libreoffice.org/78873
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
|