VirtualBox

Changeset 101891 in vbox


Ignore:
Timestamp:
Nov 6, 2023 6:40:51 PM (16 months ago)
Author:
vboxsync
Message:

libs/xpcom: Remove more unused code in nsprpub, bugref:10545

Location:
trunk/src/libs/xpcom18a4
Files:
1 deleted
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/xpcom18a4/Makefile.kmk

    r101889 r101891  
    484484        nsprpub/pr/src/io/priometh.c \
    485485        nsprpub/pr/src/io/prmapopt.c \
    486         nsprpub/pr/src/io/prlayer.c \
    487486        nsprpub/pr/src/io/prlog.c \
    488487        nsprpub/pr/src/io/prprf.c \
  • trunk/src/libs/xpcom18a4/nsprpub/pr/include/prio.h

    r101874 r101891  
    16221622    PRPollDesc *pds, PRIntn npds, PRIntervalTime timeout);
    16231623
    1624 /*
    1625 **************************************************************************
    1626 **
    1627 ** Pollable events
    1628 **
    1629 ** A pollable event is a special kind of file descriptor.
    1630 ** The only I/O operation you can perform on a pollable event
    1631 ** is to poll it with the PR_POLL_READ flag.  You can't
    1632 ** read from or write to a pollable event.
    1633 **
    1634 ** The purpose of a pollable event is to combine event waiting
    1635 ** with I/O waiting in a single PR_Poll call.  Pollable events
    1636 ** are implemented using a pipe or a pair of TCP sockets
    1637 ** connected via the loopback address, therefore setting and
    1638 ** waiting for pollable events are expensive operating system
    1639 ** calls.  Do not use pollable events for general thread
    1640 ** synchronization. Use condition variables instead.
    1641 **
    1642 ** A pollable event has two states: set and unset.  Events
    1643 ** are not queued, so there is no notion of an event count.
    1644 ** A pollable event is either set or unset.
    1645 **
    1646 ** A new pollable event is created by a PR_NewPollableEvent
    1647 ** call and is initially in the unset state.
    1648 **
    1649 ** PR_WaitForPollableEvent blocks the calling thread until
    1650 ** the pollable event is set, and then it atomically unsets
    1651 ** the pollable event before it returns.
    1652 **
    1653 ** To set a pollable event, call PR_SetPollableEvent.
    1654 **
    1655 ** One can call PR_Poll with the PR_POLL_READ flag on a pollable
    1656 ** event.  When the pollable event is set, PR_Poll returns with
    1657 ** the PR_POLL_READ flag set in the out_flags.
    1658 **
    1659 ** To close a pollable event, call PR_DestroyPollableEvent
    1660 ** (not PR_Close).
    1661 **
    1662 **************************************************************************
    1663 */
    1664 
    1665 NSPR_API(PRFileDesc *) PR_NewPollableEvent(void);
    1666 
    1667 NSPR_API(PRStatus) PR_DestroyPollableEvent(PRFileDesc *event);
    1668 
    1669 NSPR_API(PRStatus) PR_SetPollableEvent(PRFileDesc *event);
    1670 
    1671 NSPR_API(PRStatus) PR_WaitForPollableEvent(PRFileDesc *event);
    1672 
    16731624PR_END_EXTERN_C
    16741625
  • trunk/src/libs/xpcom18a4/nsprpub/pr/src/misc/prinit.c

    r101875 r101891  
    154154        _PR_InitTPD();
    155155    _PR_InitEnv();
    156     _PR_InitLayerCache();
    157156    _PR_InitClock();
    158157
  • trunk/src/libs/xpcom18a4/nsprpub/pr/src/pthreads/ptio.c

    r101872 r101891  
    26722672}  /* PR_DestroySocketPollFd */
    26732673
     2674#ifdef VBOX
     2675PR_IMPLEMENT(PRFileDesc*) PR_GetIdentitiesLayer(PRFileDesc* fd, PRDescIdentity id)
     2676{
     2677    PRFileDesc *layer = fd;
     2678
     2679    if (PR_TOP_IO_LAYER == id) {
     2680        if (PR_IO_LAYER_HEAD == fd->identity)
     2681                        return fd->lower;
     2682                else
     2683                        return fd;
     2684        }
     2685
     2686    for (layer = fd; layer != NULL; layer = layer->lower)
     2687    {
     2688        if (id == layer->identity) return layer;
     2689    }
     2690    for (layer = fd; layer != NULL; layer = layer->higher)
     2691    {
     2692        if (id == layer->identity) return layer;
     2693    }
     2694    return NULL;
     2695}  /* PR_GetIdentitiesLayer */
     2696#endif
     2697
    26742698PR_IMPLEMENT(PRInt32) PR_FileDesc2NativeHandle(PRFileDesc *bottom)
    26752699{
  • trunk/src/libs/xpcom18a4/nsprpub/pr/src/pthreads/ptthread.c

    r101813 r101891  
    977977        PR_DestroyLock(_pr_sleeplock);
    978978        _pr_sleeplock = NULL;
    979         _PR_CleanupLayerCache();
    980979        _PR_CleanupEnv();
    981980        _pr_initialized = PR_FALSE;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette