[vlc-devel] commit: Usage: vlc, not Usage: libvlc ( Rémi Denis-Courmont )

git version control git at videolan.org
Sun Sep 7 19:48:14 CEST 2008


vlc | branch: 0.9-bugfix | Rémi Denis-Courmont <rdenis at simphalempin.com> | Sun Sep  7 20:49:19 2008 +0300| [a92cdf589dc792b085e279be8b04e0a09138e8ac] | committer: Rémi Denis-Courmont 

Usage: vlc, not Usage: libvlc

(cherry picked from commit f44cc88bb7f3dd44fa5da6a175ffbe4cd444f485)

Conflicts:

	src/libvlc.c

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a92cdf589dc792b085e279be8b04e0a09138e8ac
---

 src/libvlc.c |   18 +++---------------
 1 files changed, 3 insertions(+), 15 deletions(-)

diff --git a/src/libvlc.c b/src/libvlc.c
index 3820ef3..58c2124 100644
--- a/src/libvlc.c
+++ b/src/libvlc.c
@@ -271,18 +271,6 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
     /* System specific initialization code */
     system_Init( p_libvlc, &i_argc, ppsz_argv );
 
-    /* Get the executable name (similar to the basename command) */
-    if( i_argc > 0 && ppsz_argv[0][0] )
-    {
-        free( p_libvlc->psz_object_name );
-
-        const char *psz_exe = strrchr( ppsz_argv[0], '/' );
-        if( psz_exe && *(psz_exe + 1) )
-            p_libvlc->psz_object_name = strdup( psz_exe + 1 );
-        else
-            p_libvlc->psz_object_name = strdup( ppsz_argv[0] );
-    }
-
     /*
      * Support for gettext
      */
@@ -1298,20 +1286,20 @@ static void Help( libvlc_int_t *p_this, char const *psz_help_name )
 
     if( psz_help_name && !strcmp( psz_help_name, "help" ) )
     {
-        utf8_fprintf( stdout, vlc_usage, p_this->psz_object_name );
+        utf8_fprintf( stdout, vlc_usage, "vlc" );
         Usage( p_this, "help" );
         Usage( p_this, "main" );
         print_help_on_full_help();
     }
     else if( psz_help_name && !strcmp( psz_help_name, "longhelp" ) )
     {
-        utf8_fprintf( stdout, vlc_usage, p_this->psz_object_name );
+        utf8_fprintf( stdout, vlc_usage, "vlc" );
         Usage( p_this, NULL );
         print_help_on_full_help();
     }
     else if( psz_help_name && !strcmp( psz_help_name, "full-help" ) )
     {
-        utf8_fprintf( stdout, vlc_usage, p_this->psz_object_name );
+        utf8_fprintf( stdout, vlc_usage, "vlc" );
         Usage( p_this, NULL );
     }
     else if( psz_help_name )




More information about the vlc-devel mailing list