Method

GLibStringChunkinsert

Declaration

gchar*
g_string_chunk_insert (
  GStringChunk* chunk,
  const gchar* string
)

Description

Adds a copy of string to the GStringChunk. It returns a pointer to the new copy of the string in the GStringChunk. The characters in the string can be changed, if necessary, though you should not change anything after the end of the string.

Unlike g_string_chunk_insert_const(), this function does not check for duplicates. Also strings added with g_string_chunk_insert() will not be searched by g_string_chunk_insert_const() when looking for duplicates.

Parameters

string

Type: const gchar*

The string to add.

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

Return value

Type: gchar*

A pointer to the copy of string within the GStringChunk.

The caller of the method takes ownership of the data, and is responsible for freeing it.
The value is a NUL terminated UTF-8 string.