Date: prev next · Thread: first prev next last
2018 Archives by date, by thread · List index


Hi,

Please find the latest report on new defect(s) introduced to LibreOffice found with Coverity Scan.

2 new defect(s) introduced to LibreOffice found with Coverity Scan.
7 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by 
Coverity Scan.

New defect(s) Reported-by: Coverity Scan
Showing 2 of 2 defect(s)


** CID 1433774:    (CHECKED_RETURN)
/dbaccess/qa/unit/hsql_binary_import.cxx: 63 in HsqlBinaryImportTest::testBinaryImport()()
/dbaccess/qa/unit/hsql_binary_import.cxx: 77 in HsqlBinaryImportTest::testBinaryImport()()


________________________________________________________________________________________________________
*** CID 1433774:    (CHECKED_RETURN)
/dbaccess/qa/unit/hsql_binary_import.cxx: 63 in HsqlBinaryImportTest::testBinaryImport()()
57                       "\"Birth_date\" FROM \"TestTable\" ORDER BY \"ID\"" };
58     
59         uno::Reference<XResultSet> xRes = statement->executeQuery(sql);
60         uno::Reference<XRow> xRow(xRes, UNO_QUERY_THROW);
61     
62         // assert first row
    CID 1433774:    (CHECKED_RETURN)
    Calling "next" without checking return value (as is done elsewhere 189 out of 197 times).
63         xRes->next();
64         constexpr sal_Int16 idExpected = 1;
65         CPPUNIT_ASSERT_EQUAL(idExpected, xRow->getShort(1));
66         CPPUNIT_ASSERT_EQUAL(OUString{ "45.32" }, xRow->getString(2)); // numeric
67         CPPUNIT_ASSERT_EQUAL(OUString{ "laser eye" }, xRow->getString(3)); // varchar
68         CPPUNIT_ASSERT(xRow->getBoolean(4)); // boolean
/dbaccess/qa/unit/hsql_binary_import.cxx: 77 in HsqlBinaryImportTest::testBinaryImport()()
71     
72         CPPUNIT_ASSERT_EQUAL(sal_uInt16{ 15 }, date.Day);
73         CPPUNIT_ASSERT_EQUAL(sal_uInt16{ 1 }, date.Month);
74         CPPUNIT_ASSERT_EQUAL(sal_Int16{ 1996 }, date.Year);
75     
76         // assert second row
    CID 1433774:    (CHECKED_RETURN)
    Calling "next" without checking return value (as is done elsewhere 189 out of 197 times).
77         xRes->next();
78         constexpr sal_Int16 secondIdExpected = 2;
79         CPPUNIT_ASSERT_EQUAL(secondIdExpected, xRow->getShort(1)); // ID
80         CPPUNIT_ASSERT_EQUAL(OUString{ "54.12" }, xRow->getString(2)); // numeric
81         CPPUNIT_ASSERT_EQUAL(OUString{ "telekinesis" }, xRow->getString(3)); // varchar
82         CPPUNIT_ASSERT(!xRow->getBoolean(4)); // boolean

** CID 1433773:  Incorrect expression  (USELESS_CALL)


________________________________________________________________________________________________________
*** CID 1433773:  Incorrect expression  (USELESS_CALL)
/connectivity/source/drivers/firebird/Driver.cxx: 78 in 
connectivity::firebird::FirebirdDriver::FirebirdDriver(const 
com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> &)()
72         , m_firebirdTMPDirectory(nullptr, true)
73         , m_firebirdLockDirectory(nullptr, true)
74     {
75         // Note: TempFile caches the URL on first access; call this here so that
76         // ~FirebirdDriver is not the first access, because that is called
77         // when the ServiceManager is disposing, so GetURL() would fail!
    CID 1433773:  Incorrect expression  (USELESS_CALL)
    Calling "this->m_firebirdTMPDirectory.GetURL()" is only useful for its return value, which 
is ignored.
78         m_firebirdTMPDirectory.GetURL();
79         m_firebirdLockDirectory.GetURL();
80     
81         // ::utl::TempFile uses a unique temporary directory (subdirectory of
82         // /tmp or other user specific tmp directory) per instance in which
83         // we can create directories for firebird at will.


________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, 
https://u2389337.ct.sendgrid.net/wf/click?upn=08onrYu34A-2BWcWUl-2F-2BfV0V05UPxvVjWch-2Bd2MGckcRZBnDJeNb0HijxaS4JNJPxk3kpyAm2AYqo71yXmnOxB72ibeUH-2F-2F1Lhi9AZq3dRu-2F4-3D_g-2BrHdvqzaBa155F-2F8AmPhpJzY63UzWDisJV95WUBpGhqFw1ICExHG8aMaV2EoFpyKOs2EWMysHn-2BF3l1lJPbURuQ4c2MzhsdYRdsjrDsJyp-2FzdfDcKaH94ZSGcV9J-2BzDBfdfNJpAN4E6kTP1IVhdPbF1IDccRI6cZ9nmnkXINkl39Qy5i0KyE-2F6ZBBD3Cbj-2FBDtqd6XhiPLwdWtQ1RfBzWFpvhmpNoPGtrTf9wqx-2B58-3D


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.