Closes the specified group

Procedure:

H5G_CLOSE(group_id)

Signature:

<pre><code class="language-c">herr_t H5Gclose(hid_t group_id)</code></pre>

<pre><code class="language-fortran">SUBROUTINE h5gclose_f( gr_id, hdferr)
  IMPLICIT NONE
  INTEGER(HID_T), INTENT(IN) :: gr_id     ! Group identifier
  INTEGER, INTENT(OUT) :: hdferr          ! Error code 
                                          ! 0 on success and -1 on failure
END SUBROUTINE h5gclose_f</code></pre>

Parameters:
hid_t group_id    IN: Group identifier to release

Description:

H5G_CLOSE releases resources used by a group which was opened by H5G_CREATE* or H5G_OPEN*. After closing a group, the group_id cannot be used again.

Failure to release a group with this call will result in resource leaks.

Returns:

Returns a non-negative value if successful; otherwise returns a negative value.

Example: