strdup

fun strdup(str: String? = null): String

Duplicates a string. If @str is NULL it returns NULL.

Return

a newly-allocated copy of @str

Parameters

str

the string to duplicate