Age | Commit message (Collapse) | Author |
|
remove some of the naming limitations, and handle pointer parameters
better.
I only let the plugin run up till vcl/
Change-Id: Ice916e0157031ab531c47f10778f406b07966251
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122892
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I840518a36ac43d36c95f38e09c7bfcfe1a25a525
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114984
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Add a wrapper for shared_ptr<sal_uInt8> called BinaryDataContainer,
which is used to easily manage the binary data - mainly for a
better reuse, control and to prevent duplication.
Change-Id: I68140ec379dba4a5ab1b624a334129bba2401998
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108255
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: I4b733bf37132073ece55fa392c06086410f6f914
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92393
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
which shaves 5% off the rendering time
Change-Id: Iab2a92088c5d1e8840a53ff57ab1a95ba5ec8e0a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91947
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ie99d00ea54296f5f3a909ade7115d9a9251f688e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89983
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Until now we had define GFX_LINK_FIRST_NATIVE_ID and define
GFX_LINK_LAST_NATIVE_ID which pointed to the first and last type
n the GfxLinkType which represented the native type. A more
elegant way to solve this is to assign an alias to the first and
last value. So now we have "NativeFirst" and "NativeLast" defined
in the GfxLinkType enum instead.
Change-Id: I5613a1b544fc7ae4f8b884df94c6fa4e2fb322d8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89982
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: Iae489fc31b13b836e1df5327ba2fa07e0325907a
Reviewed-on: https://gerrit.libreoffice.org/79793
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Plus a quick recheck for files in vcl/source/[a-g]*/
Found with bin/find-unneeded-includes
Only removal proposals are dealt with here.
Change-Id: Ia1ae951047be2e034da5f3b0422613ddb0a091ad
Reviewed-on: https://gerrit.libreoffice.org/78065
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Found with bin/find-unneeded-includes
Only removal proposals are dealt with here.
Change-Id: I9991a1f4d8dde51b38cf8d114e4fb69ff4a349ea
Reviewed-on: https://gerrit.libreoffice.org/75248
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Change-Id: I3bde62d674f5beaa6d19dcd22e6be15dfefe4205
Reviewed-on: https://gerrit.libreoffice.org/76118
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ie2285f64919d1c83b0a8df4ceb827f731e5cd609
Reviewed-on: https://gerrit.libreoffice.org/75739
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
I happened to get the below -fsanitize=invalid-null-argument failure just once
during `--convert-to pdf xlsx/tdf114171-1.xlsx`, presumably as a consequence of
an unknown error here.
> tools/source/stream/stream.cxx:1687:24: runtime error: null pointer passed as argument 2, which is declared to never be null
> /usr/include/string.h:43:28: note: nonnull attribute specified here
> #0 in SvMemoryStream::GetData(void*, unsigned long) at tools/source/stream/stream.cxx:1687:9
> #1 in SvStream::ReadBytes(void*, unsigned long) at tools/source/stream/stream.cxx:1232:18
> #2 in SvStream::readNumberWithoutSwap_(void*, int) at tools/source/stream/stream.cxx:149:9
> #3 in void SvStream::readNumberWithoutSwap<unsigned int>(unsigned int&) at include/tools/stream.hxx:412:7
> #4 in SvStream::ReadUInt32(unsigned int&) at tools/source/stream/stream.cxx:828:5
> #5 in GraphicDescriptor::ImpDetectGIF(SvStream&, bool) at vcl/source/filter/graphicfilter2.cxx:185:10
> #6 in GraphicDescriptor::Detect(bool) at vcl/source/filter/graphicfilter2.cxx:66:19
> #7 in ImpGraphic::ImplSetPrepared(bool, Size*) at vcl/source/gdi/impgraph.cxx:541:25
> #8 in GraphicFilter::ImportUnloadedGraphic(SvStream&, unsigned long, Size*) at vcl/source/filter/graphicfilter.cxx:1407:43
> #9 in (anonymous namespace)::GraphicProvider::queryGraphic(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) at vcl/source/graphic/UnoGraphicProvider.cxx:410:44
> #10 in non-virtual thunk to (anonymous namespace)::GraphicProvider::queryGraphic(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) at vcl/source/graphic/UnoGraphicProvider.cxx
> #11 in oox::GraphicHelper::importGraphic(com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&, WmfExternal const*) const at oox/source/helper/graphichelper.cxx:275:39
> #12 in oox::GraphicHelper::importEmbeddedGraphic(rtl::OUString const&, WmfExternal const*) const at oox/source/helper/graphichelper.cxx:363:24
> #13 in #33 in oox::xls::Shape::finalizeXShape(oox::core::XmlFilterBase&, com::sun::star::uno::Reference<com::sun::star::drawing::XShapes> const&) at sc/source/filter/oox/drawingfragment.cxx:112:30
[...]
Change-Id: I7fb38aad6b2147d650e3907d5734d8ade84353d8
Reviewed-on: https://gerrit.libreoffice.org/74165
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
redundant get() call on smart pointer
Change-Id: Icb5a03bbc15e79a30d3d135a507d22914d15c2bd
Reviewed-on: https://gerrit.libreoffice.org/61837
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
only called from one site
Change-Id: I2f8cb927df2f4f389c5d1bee19845aed5535663b
Reviewed-on: https://gerrit.libreoffice.org/61437
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
rtl/string.hxx and rtl/ustring.hxx both unnecessarily #include <sal/log.hxx> (and don't make use of it themselves), but many other files happen to depend on it.
This is a continuation of commit 6ff2d84ade299cb3d14d4110e4cf1a4b8070c030 to be able to remove those unneeded includes.
This commit adds missing headers to every file found by:
grep -FwL sal/log.hxx $(git grep -Elw 'SAL_INFO|SAL_INFO_IF|SAL_WARN|SAL_WARN_IF|SAL_DETAIL_LOG_STREAM|SAL_WHERE|SAL_STREAM|SAL_DEBUG')
to directory vcl
Change-Id: I205fe0f4e80a66cd9c3b19f7e9716411da1d1cf5
Reviewed-on: https://gerrit.libreoffice.org/58221
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
|
|
in documents, don't change them to wmf and image/x-wmf
silently, resulting for example, dropping or rejecting
modified documents by firewall packet filtering.
Change-Id: I3b8634ae022c7c026b0ed4ebc345c1c3b3f96337
Reviewed-on: https://gerrit.libreoffice.org/56045
Reviewed-by: László Németh <nemeth@numbertext.org>
Tested-by: László Németh <nemeth@numbertext.org>
|
|
When a document is loaded it takes a lot of time and memory to
load the graphic that are in the documet, so avoid that and just
store the compressed graphic into a temporary file (handeled by
GfxLink) and load when we really need to show the graphic.
GraphicObject cached some attributes from Graphic, but this
attributes now aren't available immediately so this attributes
are removed form GraphicObject and now delegate to the Graphic
itself. GetSizeBytes attribute however was removed as it is
only used in some tests.
GfxLink initial values were moved to the constructor and are
not set in the header file anymore (as it is the recommended
way to do it).
The SdImportTest::testDocumentLayout failed as it looks like the
dump sometimes didn't include the width and height of the null
bitmap (which is set to 32x32) of the FillBitmap in some
situations, but then in other situations it did include this
attributes. With this change the width and height are always
included for the FillBitmap which looks like it is more correct.
Change-Id: Ia1218f93b1735402b7828404f65660e2d4acf32f
Reviewed-on: https://gerrit.libreoffice.org/53016
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: I74d1555b461fd8ea316380423fcde2d167714170
|
|
exactly one use site
Change-Id: Id0a75d46c459be213e81b47aa6c1194c87aec848
Reviewed-on: https://gerrit.libreoffice.org/42891
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
look for statements like
return (function());
Change-Id: I906cf2183489f87225b99b987caca67e39b26cc3
Reviewed-on: https://gerrit.libreoffice.org/41260
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
with command
> git grep -l tools/debug.hxx |
xargs grep -L DBG_ |
xargs sed -i '/#include *\(<\|\"\)tools\/debug.hxx.*/d'
don't change files in includes/ and */pch
Change-Id: Ie429d6a7dca5dfa1073e0f5ba037f7c84bdbec08
Reviewed-on: https://gerrit.libreoffice.org/37349
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I6b004c7f7957f3843d37063b182cac0cd07e5f44
|
|
so can just use SvFileStream here and not go through ucb
Change-Id: I1d70a4e39977a178afaf7eeadb552f1bd7d9fd1a
Reviewed-on: https://gerrit.libreoffice.org/36024
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
This reverts commit 5411d99c0a7345e9c68ad55debcb20eecdc0b36a.
|
|
|
|
Change-Id: Ic6eb0934fdb63492d831b9dad07e93c968ee9bf2
|
|
Change-Id: Ib4920d6537437fe060c453f249fa7f8da230bfc7
|
|
... except in include/rtl, include/sal, include/uno, where sal_Size is
retained for compatibility, and where callers of rtl functions pass in
pointers that are incompatible on MSVC.
Change-Id: I8344453780689f5120ba0870e44965b6d292450c
|
|
Change-Id: I503f954a2729aa2737d783ed8c72f62d8a68da4c
|
|
Change-Id: I77682f7e289a59b986bb84edf014029a20266470
Reviewed-on: https://gerrit.libreoffice.org/28420
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: I732fb1a789f90ca7a7f393cc41a6afe84fecf3d3
Reviewed-on: https://gerrit.libreoffice.org/26200
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Uses std::shared_ptr for sharing graphic data
Changed constructor to std::unique_ptr<sal_uInt8[]> to ensure
the delete[] operator is called when GfxLink internals takes
ownership of the data
Change-Id: I4edd4634df8d6ba4d94953260c1a7ac560ccf04a
Reviewed-on: https://gerrit.libreoffice.org/25402
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: Ib788a30d413436aa03f813aa2fddcbc4d6cd2f9a
Reviewed-on: https://gerrit.libreoffice.org/25972
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
|
|
Change-Id: Iae074ef0927a55f1fbf401cb66f4f183213f547c
Reviewed-on: https://gerrit.libreoffice.org/25656
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
This reverts commit d64431ac5a7bede7661c64e0bd6d46805841e704, which caused ASan
to complain about "alloc-dealloc-mismatch (operator new [] vs operator delete)"
(while e.g. building Gallery_arrows), as GfxLink::mpSwpInData is a
std::shared_ptr<sal_uInt8> holding a pointer to an array of sal_uInt8.
|
|
The functionality has not changed in this class, however the ABI
has changed (this class is DLL Public)
Change-Id: I11005f03e747d56cb59550e071755429390db7a7
Reviewed-on: https://gerrit.libreoffice.org/25081
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
more regressions from commit db17d3c1 "new loplugin: memoryvar"
Change-Id: I611697f2bc818f2f42a704bfb5297637c30060c9
|
|
Change-Id: I3774661799c074561c694515baba42a375d0a077
Reviewed-on: https://gerrit.libreoffice.org/23301
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
also some improvements to the plugin
Change-Id: I0e3a519d70756e577fcb1bd47dd66864b5b4c871
Reviewed-on: https://gerrit.libreoffice.org/23289
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: I987bf68c767709080c67c8b183c036a4109c6caa
|
|
Change-Id: Ia5bbce27d9e9526122ce1e27389c7845e6709f27
|
|
A ridiculously fast way of doing this is:
for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \
--exclude-dir=workdir --exclude-dir=instdir '^
{3,}' .)
do
perl -0777 -i -pe 's/^
{3,}/
/gm' $i
done
Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c
Reviewed-on: https://gerrit.libreoffice.org/22224
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
|
|
detect when we can convert a new/delete sequence on a local variable to
use std::unique_ptr
Change-Id: Iecae4e4197eccdfacfce2eed39aa4a69e4a660bc
Reviewed-on: https://gerrit.libreoffice.org/19884
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: I05e89f9896170d4df3d1377549ea074f06b884a0
|
|
Change-Id: I0752cbb0cb2e0f89607d81d9eda7ce7091449fd6
|
|
Change-Id: I7703816b6a1df2bf24c06cdf9992f9982ae724e8
Reviewed-on: https://gerrit.libreoffice.org/15826
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: I17c57a85bcda98ef36ddefd6562d4681d0c7d5fc
|
|
Change-Id: I9219619b538b6530a89f5932ac51eb3b62eb396a
|
|
Change-Id: I74d35630b9fcdaa97af0b1f1e6d1e5c72488964d
|