[PATCH] cppCheck: redundant assignment and Possible null pointer der...

Christophe JAILLET (via Code Review) gerrit at gerrit.libreoffice.org
Fri Nov 9 05:27:27 PST 2012


Hi,

I have submitted a patch for review:

    https://gerrit.libreoffice.org/1015

To pull it, you can do:

    git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/15/1015/1

cppCheck: redundant assignment and Possible null pointer dereference.

Test against pOldFormat is useless because it is already used above.
Could it be NULL, then this part of the function should be written another way.

I also turned a memmove into a memcpy. The 2 memory areas can not overlap.

Change-Id: Id4f984f9eb5dea1ba59631281d6967d259948e5b
---
M sc/source/ui/docshell/docfunc.cxx
1 file changed, 3 insertions(+), 6 deletions(-)


--
To view, visit https://gerrit.libreoffice.org/1015
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id4f984f9eb5dea1ba59631281d6967d259948e5b
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Christophe JAILLET <christophe.jaillet at wanadoo.fr>



More information about the LibreOffice mailing list