[Libreoffice-commits] core.git: 2 commits - canvas/source connectivity/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Sun Oct 21 20:03:03 UTC 2018
canvas/source/directx/dx_surfacebitmap.cxx | 14 ++++++++------
connectivity/source/drivers/mork/MQueryHelper.cxx | 5 ++---
2 files changed, 10 insertions(+), 9 deletions(-)
New commits:
commit c2145978f64d24260df88b7ebf86f5fc48149914
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sat Oct 20 19:26:58 2018 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun Oct 21 22:02:51 2018 +0200
pvs-studio: Expression 'condition == MQueryExpression::AND' is always true.
Change-Id: Ib3c5a5a09eff26acabf64e4cbc2e7019ca3264e6
Reviewed-on: https://gerrit.libreoffice.org/62098
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/connectivity/source/drivers/mork/MQueryHelper.cxx b/connectivity/source/drivers/mork/MQueryHelper.cxx
index 307613f936fd..f53e7e619cef 100644
--- a/connectivity/source/drivers/mork/MQueryHelper.cxx
+++ b/connectivity/source/drivers/mork/MQueryHelper.cxx
@@ -308,15 +308,14 @@ std::vector<bool> entryMatchedByExpression(MQueryHelper* _aQuery, MQueryExpressi
result = result || elem;
}
resultVector.push_back(result);
- } else if (condition == MQueryExpression::AND) {
+ } else {
+ assert(condition == MQueryExpression::AND && "only OR or AND should exist");
bool result = true;
for (auto const& elem : subquery_result)
{
result = result && elem;
}
resultVector.push_back(result);
- } else {
- OSL_FAIL("Unknown Expression Type");
}
}
else {
commit 28acf83a9c07081d8a818f1dddb74b48d0188512
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sat Oct 20 19:06:08 2018 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun Oct 21 22:02:40 2018 +0200
pvs-studio: initialize maLockedRect
Change-Id: If95854af5072c9e693bec4011cdcd6c041dffdf3
Reviewed-on: https://gerrit.libreoffice.org/62094
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/canvas/source/directx/dx_surfacebitmap.cxx b/canvas/source/directx/dx_surfacebitmap.cxx
index 2e4548677bc5..17f0a7bf9ddd 100644
--- a/canvas/source/directx/dx_surfacebitmap.cxx
+++ b/canvas/source/directx/dx_surfacebitmap.cxx
@@ -46,9 +46,10 @@ namespace dxcanvas
{
public:
DXColorBuffer( const COMReference<surface_type>& rSurface,
- const ::basegfx::B2IVector& rSize ) :
- maSize(rSize),
- mpSurface(rSurface)
+ const ::basegfx::B2IVector& rSize )
+ : maSize(rSize)
+ , maLockedRect{}
+ , mpSurface(rSurface)
{
}
@@ -110,9 +111,10 @@ namespace dxcanvas
public:
GDIColorBuffer( const BitmapSharedPtr& rSurface,
- const ::basegfx::B2IVector& rSize ) :
- maSize(rSize),
- mpGDIPlusBitmap(rSurface)
+ const ::basegfx::B2IVector& rSize )
+ : maSize(rSize)
+ , aBmpData{}
+ , mpGDIPlusBitmap(rSurface)
{
}
More information about the Libreoffice-commits
mailing list