Commit d3c13734 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Cleanup

parent 4832f086
...@@ -947,13 +947,7 @@ char *E_(RealPath)( intf_thread_t *p_intf, const char *psz_src ) ...@@ -947,13 +947,7 @@ char *E_(RealPath)( intf_thread_t *p_intf, const char *psz_src )
char *psz_dir; char *psz_dir;
char *p; char *p;
int i_len = strlen(psz_src); int i_len = strlen(psz_src);
char sep; const char sep = DIR_SEP_CHAR;
#if defined( WIN32 )
sep = '\\';
#else
sep = '/';
#endif
psz_dir = malloc( i_len + 2 ); psz_dir = malloc( i_len + 2 );
strcpy( psz_dir, psz_src ); strcpy( psz_dir, psz_src );
...@@ -962,7 +956,7 @@ char *E_(RealPath)( intf_thread_t *p_intf, const char *psz_src ) ...@@ -962,7 +956,7 @@ char *E_(RealPath)( intf_thread_t *p_intf, const char *psz_src )
psz_dir[i_len] = sep; psz_dir[i_len] = sep;
psz_dir[i_len + 1] = '\0'; psz_dir[i_len + 1] = '\0';
#ifdef WIN32 #if (DIR_SEP_CHAR != '/')
/* Convert all / to native separator */ /* Convert all / to native separator */
p = psz_dir; p = psz_dir;
while( (p = strchr( p, '/' )) != NULL ) while( (p = strchr( p, '/' )) != NULL )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment