2 new defect(s) introduced to LibreOffice found with Coverity Scan.
5 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 1455691:  Null pointer dereferences  (REVERSE_INULL)
/sw/source/uibase/shells/drwtxtex.cxx: 660 in
SwDrawTextShell::Execute(SfxRequest &)()
___________________________________________________________________
__
___________________________________
*** CID 1455691:  Null pointer dereferences  (REVERSE_INULL)
/sw/source/uibase/shells/drwtxtex.cxx: 660 in
SwDrawTextShell::Execute(SfxRequest &)()
654                 return;
655         }
656     
657         std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs-
Clone();
658         lcl_convertStringArguments(nSlot, pNewArgs);
659     
    CID 1455691:  Null pointer dereferences  (REVERSE_INULL)
    Null-checking "pNewAttrs" suggests that it may be null,
but
it has already been dereferenced on all paths leading to the
check.
660         if(nEEWhich && pNewAttrs)
661         {
662             std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs-
Get(nWhich).CloneSetWhich(nEEWhich));
663             pNewArgs->Put(*pNewItem);
664         }
665     
** CID 1455690:    (FORWARD_NULL)
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
___________________________________________________________________
__
___________________________________
*** CID 1455690:    (FORWARD_NULL)
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
651     
652             default:
653                 assert(false && "wrong dispatcher");
654                 return;
655         }
656     
    CID 1455690:    (FORWARD_NULL)
    Passing null pointer "pNewAttrs" to "Clone", which
dereferences it. (The dereference happens because this is a
virtual function call.)
657         std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs-
Clone();
658         lcl_convertStringArguments(nSlot, pNewArgs);
659     
660         if(nEEWhich && pNewAttrs)
661         {
662             std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs-
Get(nWhich).CloneSetWhich(nEEWhich));
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
651     
652             default:
653                 assert(false && "wrong dispatcher");
654                 return;
655         }
656     
    CID 1455690:    (FORWARD_NULL)
    Passing null pointer "pNewAttrs" to "Clone", which
dereferences it. (The dereference happens because this is a
virtual function call.)
657         std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs-
Clone();
658         lcl_convertStringArguments(nSlot, pNewArgs);
659     
660         if(nEEWhich && pNewAttrs)
661         {
662             std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs-
Get(nWhich).CloneSetWhich(nEEWhich));
/sw/source/uibase/shells/drwtxtex.cxx: 657 in
SwDrawTextShell::Execute(SfxRequest &)()
651     
652             default:
653                 assert(false && "wrong dispatcher");
654                 return;
655         }
656     
    CID 1455690:    (FORWARD_NULL)
    Passing null pointer "pNewAttrs" to "Clone", which
dereferences it. (The dereference happens because this is a
virtual function call.)
657         std::unique_ptr<SfxItemSet> pNewArgs = pNewAttrs-
Clone();
658         lcl_convertStringArguments(nSlot, pNewArgs);
659     
660         if(nEEWhich && pNewAttrs)
661         {
662             std::unique_ptr<SfxPoolItem> pNewItem(pNewArgs-
Get(nWhich).CloneSetWhich(nEEWhich));