summaryrefslogtreecommitdiff
path: root/sax
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2019-04-14 15:54:14 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2019-04-14 15:47:48 +0200
commit6154489314d2f2bf9cb99b72f15c79dd48a1da14 (patch)
treed9bbbc2e0233d417555109206bdb2d298ce838ac /sax
parenteb772683513f4f2b6c8e6404c29b8e477ffc7fad (diff)
tdf#120703 PVS: V581 ifs with identical conditions
V581 The conditional expressions of the 'if' statements situated alongside each other are identical. Change-Id: I18562d60e33c7ecff14807976dde4cbcae3f665b Reviewed-on: https://gerrit.libreoffice.org/70731 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sax')
-rw-r--r--sax/source/tools/converter.cxx16
1 files changed, 1 insertions, 15 deletions
diff --git a/sax/source/tools/converter.cxx b/sax/source/tools/converter.cxx
index dce277b3e464..cfd3b3083d40 100644
--- a/sax/source/tools/converter.cxx
+++ b/sax/source/tools/converter.cxx
@@ -1565,10 +1565,7 @@ static bool lcl_parseDate(
if (bSuccess)
{
++nPos;
- }
- if (bSuccess)
- {
bSuccess = readDateTimeComponent(string, nPos, nMonth, 2, true);
if (!bIgnoreInvalidOrMissingDate)
{
@@ -1584,10 +1581,7 @@ static bool lcl_parseDate(
if (bSuccess)
{
++nPos;
- }
- if (bSuccess)
- {
bSuccess = readDateTimeComponent(string, nPos, nDay, 2, true);
if (!bIgnoreInvalidOrMissingDate)
{
@@ -1662,10 +1656,7 @@ static bool lcl_parseDateTime(
if (bSuccess)
{
++nPos;
- }
- if (bSuccess)
- {
bSuccess = readDateTimeComponent(string, nPos, nMinutes, 2, true);
bSuccess &= (0 <= nMinutes) && (nMinutes < 60);
bSuccess &= (nPos < string.getLength()); // not last token
@@ -1677,10 +1668,7 @@ static bool lcl_parseDateTime(
if (bSuccess)
{
++nPos;
- }
- if (bSuccess)
- {
bSuccess = readDateTimeComponent(string, nPos, nSeconds, 2, true);
bSuccess &= (0 <= nSeconds) && (nSeconds < 60);
}
@@ -1758,9 +1746,7 @@ static bool lcl_parseDateTime(
if (bSuccess)
{
++nPos;
- }
- if (bSuccess)
- {
+
bSuccess = readDateTimeComponent(
string, nPos, nTimezoneMinutes, 2, true);
bSuccess &= (0 <= nTimezoneMinutes) && (nTimezoneMinutes < 60);