pre-inst/pre-inst.c
changeset 89 e87a7db919c6
parent 80 671df13f1304
child 94 0e1a57225c62
     1.1 --- a/pre-inst/pre-inst.c	Wed Aug 22 23:29:22 2018 +0100
     1.2 +++ b/pre-inst/pre-inst.c	Fri Mar 08 13:51:08 2019 +0000
     1.3 @@ -358,7 +358,7 @@
     1.4      int exit_status;
     1.5  #endif
     1.6      GError *tmp_error=NULL;
     1.7 -    if (argc<1)
     1.8 +    if (argc<2)
     1.9      {
    1.10  	g_set_error_literal(error,G_FILE_ERROR,G_FILE_ERROR_NOENT,
    1.11  	  "--post: No command given");
    1.12 @@ -519,7 +519,7 @@
    1.13  	success=!!pre_install(path);
    1.14  #endif
    1.15      }
    1.16 -    if (enable_post && !run_post(argc-1,argv+1,success,&error))
    1.17 +    if (enable_post && !run_post(argc,argv,success,&error))
    1.18      {
    1.19  #ifndef WIN32
    1.20  	fprintf(stderr,"Error in post: %s\n",error->message);