On Thu, 2013-01-17 at 13:54 -0800, julien2412 wrote:
What should we do with bRet value, after line 1102?
bRet is supposed to return true if the save succeeded s
a) changing all the bRets after the initial initialization from
bRet = foo
to
bRet &= foo
would ensure that the failed state of any check is kept
b) alternatively, could change the
bool bRet = ...
if (bRet)
{
    bRet = foo
    bRet = bar
}
to something like
bool bRet = true;
do
{
    bRet = foo;
    if (!bRet)
        break;
    bRet = bar;
    if (!bRet)
       break;
    
} while(0);
c) just do one bRet = (rStream.GetError() == 0); before the Flush and
remove the other ones inside the bRet block
Also, notice the line 1107 "++it" to skip the first item. Shouldn't we add a
wrapper if(it != itEnd) for the "for loop" to be sure?
Yeah, I think you definitely should
C.
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.