Back to index

lightdm  1.3.2
lightdm-guest-session-wrapper.c File Reference
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>

Go to the source code of this file.


int main (int argc, char *argv[], char *envp[])

Function Documentation

int main ( int  argc,
char *  argv[],
char *  envp[] 

Definition at line 24 of file lightdm-guest-session-wrapper.c.

    if (argc < 2)
        fprintf (stderr, "Usage: %s COMMAND [ARGS]\n", argv[0]);
        return EXIT_FAILURE;

    execve (argv[1], argv+1, envp);

    fprintf (stderr, "Failed to run guest session '%s': %s\n", argv[1], strerror (errno));

    return EXIT_FAILURE;