Function

GLib-2.0GLibtry_realloc_nSince 2.24

  • This function is similar to g_try_realloc(), allocating (n_blocks * n_block_bytes) bytes, but care is taken to detect possible overflow during multiplication.

    Parameters

    • mem: any

      previously-allocated memory, or null.

    • n_blocks: number

      the number of blocks to allocate

    • n_block_bytes: number

      the size of each block in bytes

    Returns any

    the allocated memory, or null.

    2.24