### Method

# Meta WaylandClient spawn

#### Declaration [src]

    GSubprocess*
    meta_wayland_client_spawn (
      MetaWaylandClient* client,
      MetaDisplay* display,
      GError** error,
      const char* argv0,
      ...
    )

#### Description [src]

Creates a `GSubprocess` given a provided varargs list of arguments. It also sets up a new Wayland socket and sets the environment variable WAYLAND_SOCKET to make the new process to use it.

This method is not directly available to language bindings.

#### Parameters

`display`

  Type: `MetaDisplay`

  The current MetaDisplay.

  The data is owned by the caller of the function.

`error`

  Type: `GError`

  Error.

  The argument can be `NULL`.
  The data is owned by the caller of the function.

`argv0`

  Type: `const char*`

  Command line arguments.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`...`

  Type: ``

  Continued arguments, `NULL` terminated.

#### Return value

Type: `GSubprocess`

A new `GSubprocess`, or `NULL` on error (and `error` will be set)

The caller of the method takes ownership of the data, and is responsible for freeing it.