https://bugs.freedesktop.org/show_bug.cgi?id=84323
Priority: medium
Bug ID: 84323
Assignee: [email protected]
Summary: sal - cleanup osl_waitThread
Severity: normal
Classification: Unclassified
OS: All
Reporter: [email protected]
Hardware: Other
Status: UNCONFIRMED
Version: 4.3.0.2 rc
Component: Libreoffice
Product: LibreOffice
LibreOffice has a nice 'usleep' style function - but its docs suck.
the method is osl_waitThread - and it is sufficiently opaque that I couldn't
find it:
include/osl/thread.h
/** Blocks the calling thread at least for the given number
of time.
*/
SAL_DLLPUBLIC void SAL_CALL osl_waitThread(const TimeValue* pDelay);
That comment needs to be longer, describe the parameter, and mention the string
'sleep' and also 'usleep' ideally =)
It might be nice to have a usleep version that sets up the TimeValue for you in
the hxx header too:
static void SAL_CALL wait(const TimeValue& Delay)
{
osl_waitThread(&Delay);
}
And then we should fix the call-sites that cooked their own version; even
inside sal/ this happens:
cd sal ; git grep -5 Sleep
to find the several instances that need to be cleaned up here =)
Thanks !
--
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