VLC_EXPORT( long long, vlc_strtoll, ( const char *nptr, char **endptr, int base ) LIBVLC_USED );
VLC_EXPORT( char *, vlc_strcasestr, ( const char *s1, const char *s2 ) LIBVLC_USED );
-char *vlc_strsep( char **, const char * );
#if defined(WIN32) || defined(UNDER_CE)
/* win32, cl and icl support */
#endif
#ifndef HAVE_STRSEP
-# define strsep vlc_strsep
+static inline char *vlc_strsep( char **ppsz_string, const char *psz_delimiters )
+{
+ char *psz_string = *ppsz_string;
+ if( !psz_string )
+ return NULL;
+
+ char *p = strpbrk( psz_string, psz_delimiters );
+ if( !p )
+ {
+ *ppsz_string = NULL;
+ return psz_string;
+ }
+ *p++ = '\0';
+
+ *ppsz_string = p;
+ return psz_string;
+}
#endif
#ifndef HAVE_ATOLL
#endif
}
-/**
- * Extract a token from string.
- * It is a replacement for strsep if not present.
- */
-char *vlc_strsep( char **ppsz_string, const char *psz_delimiters )
-{
- char *psz_string = *ppsz_string;
- if( !psz_string )
- return NULL;
-
- char *p = strpbrk( psz_string, psz_delimiters );
- if( !p )
- {
- *ppsz_string = NULL;
- return psz_string;
- }
- *p++ = '\0';
-
- *ppsz_string = p;
- return psz_string;
-}
-
/*****************************************************************************
* vlc_*dir_wrapper: wrapper under Windows to return the list of drive letters
* when called with an empty argument or just '\'