### Function

# GLib strdupv

#### Declaration

    gchar**
    g_strdupv (
      gchar** str_array
    )

#### Description

Copies an array of strings. The copy is a deep copy; each string is also copied.

If called on a `NULL` value, `g_strdupv()` simply returns `NULL`.

#### Parameters

`str_array`

  Type: An array of `gchar*`

  An array of strings to copy.

  The argument can be `NULL`.
  The array must be `NULL`-terminated.
  The data is owned by the caller of the function.
  Each element is a NUL terminated UTF-8 string.

#### Return value

Type: An array of `utf8`

A newly-allocated array of strings. Use `g_strfreev()` to free it.

The array is `NULL`-terminated.
The caller of the function takes ownership of the data, and is responsible for freeing it.
The return value can be `NULL`.
Each element is a NUL terminated UTF-8 string.