https://bugs.freedesktop.org/show_bug.cgi?id=44989

             Bug #: 44989
           Summary: EasyHack: tools: SvStream: simplify LockRegion
    Classification: Unclassified
           Product: LibreOffice
           Version: LibO Master
          Platform: Other
        OS/Version: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Libreoffice
        AssignedTo: [email protected]
        ReportedBy: [email protected]


The tools/ code has some legacy 'LockRegion' and 'UnlockRegion' methods that
are only ever used by 'LockFile' and 'UnlockFile' which in turn are only used
on close and open (it seems).

We should get rid of the LockRegion / UnlockRegion methods - and since these
are only ever called with:

  return LockRange( 0UL, 0UL );
    return UnlockRange( 0UL, 0UL );

We should collapse all of their contents into LockFile/UnlockFile - and we
should propagate the conseqences of 0 length, and 0 size through the code.

That code is in tools/source/stream/strmunx.cxx and strmwnt.cxx

Do whichever platform you can compile on first :-)

We should also (as a separate patch) remove all these overly verbose function
header comments with no content except the method name that just obscure the
code :-)

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to