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


Hello Julien,
but it is used, it is an array
*sal_uInt16 p1 = pPtr[0], p2 = pPtr[1];
  while(pPtr[2] && (pPtr[2] - p2 == 1))*


On Thu, Dec 27, 2012 at 4:43 PM, julien2412 <serval2412@yahoo.fr> wrote:

Hello,

Cppcheck reported this:
[sd/source/ui/func/fupage.cxx:243]: (style) Variable 'pPtr' is assigned a
value that is never used

Here are some lines:
    236     const sal_uInt16* pPtr = aNewAttr.GetRanges();
    237     sal_uInt16 p1 = pPtr[0], p2 = pPtr[1];
    238     while(pPtr[2] && (pPtr[2] - p2 == 1))
    239     {
    240         p2 = pPtr[3];
    241         pPtr += 2;
    242     }
    243     pPtr += 2;
see
http://opengrok.libreoffice.org/xref/core/sd/source/ui/func/fupage.cxx#238
pPtr isn't used.

So either it can just be removed or something is wrong here.

Any idea?

Julien




--
View this message in context:
http://nabble.documentfoundation.org/Cppcheck-reports-an-assignment-which-isn-t-used-in-sd-source-ui-func-fupage-cxx-tp4026217.html
Sent from the Dev mailing list archive at Nabble.com.
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


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.