VirtualBox

Ignore:
Timestamp:
Nov 21, 2023 8:29:54 AM (14 months ago)
Author:
vboxsync
Message:

libs/xpcom: Replace PL_strdup/PL_strndup/PL_strfree with IPRT equivalents, bugref:10545

Location:
trunk/src/libs/xpcom18a4/nsprpub/lib/libc
Files:
1 deleted
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/xpcom18a4/nsprpub/lib/libc/include/plstr.h

    r102174 r102175  
    136136
    137137/*
    138  * PL_strdup
    139  *
    140  * Returns a pointer to a malloc'd extent of memory containing a duplicate
    141  * of the argument string.  The size of the allocated extent is one greater
    142  * than the length of the argument string, because of the terminator.  A
    143  * null argument, like a zero-length argument, will result in a pointer to
    144  * a one-byte extent containing the null value.  This routine returns null
    145  * upon malloc failure.
    146  */
    147 
    148 PR_EXTERN(char *)
    149 PL_strdup(const char *s);
    150 
    151 /*
    152  * PL_strfree
    153  *
    154  * Free memory allocated by PL_strdup
    155  */
    156 
    157 PR_EXTERN(void)
    158 PL_strfree(char *s);
    159 
    160 /*
    161  * PL_strndup
    162  *
    163  * Returns a pointer to a malloc'd extent of memory containing a duplicate
    164  * of the argument string, up to the maximum specified.  If the argument
    165  * string has a length greater than the value of the specified maximum, the
    166  * return value will be a pointer to an extent of memory of length one
    167  * greater than the maximum specified.  A null string, a zero-length string,
    168  * or a zero maximum will all result in a pointer to a one-byte extent
    169  * containing the null value.  This routine returns null upon malloc failure.
    170  */
    171 
    172 PR_EXTERN(char *)
    173 PL_strndup(const char *s, PRUint32 max);
    174 
    175 /*
    176138 * PL_strcmp
    177139 *
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