sfx2/source/toolbox/tbxitem.cxx | 12 ++++++------ ucb/source/ucp/gio/gio_seekable.cxx | 4 ---- 2 files changed, 6 insertions(+), 10 deletions(-)
New commits: commit be7a99bca77cd7176f2c01cfff42801475f90f82 Author: Caolán McNamara <caol...@redhat.com> Date: Thu Sep 25 11:36:34 2014 +0100 coverity#1240266 Logically dead code Change-Id: I97256c687c6d56beef2c3664bbba8c43f685228b diff --git a/ucb/source/ucp/gio/gio_seekable.cxx b/ucb/source/ucp/gio/gio_seekable.cxx index 26e222a..ba338c0 100644 --- a/ucb/source/ucp/gio/gio_seekable.cxx +++ b/ucb/source/ucp/gio/gio_seekable.cxx @@ -110,10 +110,6 @@ sal_Int64 SAL_CALL Seekable::getLength() throw( io::IOException, uno::RuntimeExc bOk = true; } - if (!bOk) - throw io::IOException("Getting size unsupported", - static_cast< cppu::OWeakObject * >(this)); - return nSize; } commit c7b6f0733127863ace4f351629301990f99a2178 Author: Caolán McNamara <caol...@redhat.com> Date: Thu Sep 25 11:34:58 2014 +0100 coverity#1240261 Logically dead code we must check the new proposed state for sanity, not the old state Change-Id: Iabab0ccda4942ec82b243ad07762187be916d43f diff --git a/sfx2/source/toolbox/tbxitem.cxx b/sfx2/source/toolbox/tbxitem.cxx index a6c3be4..d0486db 100644 --- a/sfx2/source/toolbox/tbxitem.cxx +++ b/sfx2/source/toolbox/tbxitem.cxx @@ -549,9 +549,9 @@ throw ( ::com::sun::star::uno::RuntimeException, std::exception ) rEvent.State >>= aItemStatus; SfxItemState tmpState = (SfxItemState) aItemStatus.State; // make sure no-one tries to send us a combination of states - if (eState != SfxItemState::UNKNOWN && eState != SfxItemState::DISABLED && - eState != SfxItemState::READONLY && eState != SfxItemState::DONTCARE && - eState != SfxItemState::DEFAULT && eState != SfxItemState::SET) + if (tmpState != SfxItemState::UNKNOWN && tmpState != SfxItemState::DISABLED && + tmpState != SfxItemState::READONLY && tmpState != SfxItemState::DONTCARE && + tmpState != SfxItemState::DEFAULT && tmpState != SfxItemState::SET) throw ::com::sun::star::uno::RuntimeException("unknown status"); eState = tmpState; pItem = new SfxVoidItem( nSlotId ); @@ -1103,9 +1103,9 @@ throw ( ::com::sun::star::uno::RuntimeException, std::exception ) rEvent.State >>= aItemStatus; SfxItemState tmpState = (SfxItemState) aItemStatus.State; // make sure no-one tries to send us a combination of states - if (eState != SfxItemState::UNKNOWN && eState != SfxItemState::DISABLED && - eState != SfxItemState::READONLY && eState != SfxItemState::DONTCARE && - eState != SfxItemState::DEFAULT && eState != SfxItemState::SET) + if (tmpState != SfxItemState::UNKNOWN && tmpState != SfxItemState::DISABLED && + tmpState != SfxItemState::READONLY && tmpState != SfxItemState::DONTCARE && + tmpState != SfxItemState::DEFAULT && tmpState != SfxItemState::SET) throw ::com::sun::star::uno::RuntimeException("unknown status"); eState = tmpState; pItem = new SfxVoidItem( nSlotId );
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits