Method

GLibDirunref

since: 2.80

Declaration

void
g_dir_unref (
  GDir* dir
)

Description

Decrements the reference count of dir.

Once the reference count reaches zero, the directory will be closed and all resources associated with it will be freed. If g_dir_close() is called when the reference count is greater than zero, the directory is closed but the GDir structure will not be freed until its reference count reaches zero.

It is an error to call any of the GDir methods other than g_dir_ref() and g_dir_unref() on a GDir after calling g_dir_close() on it.

Available since: 2.80