[vlc-devel] commit: config_ChainCreate() : use SKIPSPACE macro ( Rafaël Carré )
git version control
git at videolan.org
Tue Nov 24 13:56:47 CET 2009
vlc | branch: master | Rafaël Carré <rafael.carre at gmail.com> | Tue Nov 24 13:56:16 2009 +0100| [8fb9c70f1caabdb34eb8ad1ea6fc018b2a99d2bf] | committer: Rafaël Carré
config_ChainCreate() : use SKIPSPACE macro
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=8fb9c70f1caabdb34eb8ad1ea6fc018b2a99d2bf
---
src/config/chain.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/config/chain.c b/src/config/chain.c
index 2b1b6ad..ee94af1 100644
--- a/src/config/chain.c
+++ b/src/config/chain.c
@@ -186,7 +186,7 @@ char *config_ChainCreate( char **ppsz_name, config_chain_t **pp_cfg,
if( !psz_chain )
return NULL;
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
/* Look for parameter (a {...} or :...) or end of name (space or nul) */
len = strcspn( psz_chain, "{: \t" );
@@ -194,14 +194,14 @@ char *config_ChainCreate( char **ppsz_name, config_chain_t **pp_cfg,
psz_chain += len;
/* Parse the parameters */
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
if( *psz_chain == '{' )
{
/* Parse all name=value[,] elements */
do
{
psz_chain++; /* skip previous delimiter */
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
/* Look for the end of the name (,={}_space_) */
len = strcspn( psz_chain, "=,{} \t" );
@@ -221,17 +221,17 @@ char *config_ChainCreate( char **ppsz_name, config_chain_t **pp_cfg,
pp_next = &p_cfg->p_next;
/* Extract the option value */
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
if( strchr( "={", *psz_chain ) )
{
p_cfg->psz_value = ChainGetValue( &psz_chain );
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
}
}
while( !memchr( "}", *psz_chain, 2 ) );
if( *psz_chain ) psz_chain++; /* skip '}' */;
- psz_chain += strspn( psz_chain, " \t" );
+ SKIPSPACE( psz_chain );
}
if( *psz_chain == ':' )
More information about the vlc-devel
mailing list