Re: [Libreoffice] cppcheck detects division by 0 in sw/source/ui/vba/vbarows.cxx

2011-08-15 Thread Noel Power
On 13/08/11 09:38, Julien Nabet wrote: Hello, cppcheck detects division by 0 in sw/source/ui/vba/vbarows.cxx, line 266 I discussed this with Norbert on IRC, here what we propose to add before this line : if ((nNewWidth <= 0) || (nWidth <= 0)) { OSL_ASSERT(!((nNewWidth <= 0) || (nWidth <= 0)))

[Libreoffice] cppcheck detects division by 0 in sw/source/ui/vba/vbarows.cxx

2011-08-13 Thread Julien Nabet
Hello, cppcheck detects division by 0 in sw/source/ui/vba/vbarows.cxx, line 266 I discussed this with Norbert on IRC, here what we propose to add before this line : if ((nNewWidth <= 0) || (nWidth <= 0)) { OSL_ASSERT(!((nNewWidth <= 0) || (nWidth <= 0))); return; } (we supposed "indent