Coverage Report

Created: 2024-06-18 06:29

/src/hdf5/src/H5FAint.c
Line
Count
Source (jump to first uncovered line)
1
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2
 * Copyright by The HDF Group.                                               *
3
 * All rights reserved.                                                      *
4
 *                                                                           *
5
 * This file is part of HDF5.  The full HDF5 copyright notice, including     *
6
 * terms governing use, modification, and redistribution, is contained in    *
7
 * the COPYING file, which can be found at the root of the source code       *
8
 * distribution tree, or in https://www.hdfgroup.org/licenses.               *
9
 * If you do not have access to either file, you may request a copy from     *
10
 * help@hdfgroup.org.                                                        *
11
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
12
13
/*-------------------------------------------------------------------------
14
 *
15
 * Created:     H5FAint.c
16
 *
17
 * Purpose:     Internal routines for fixed arrays.
18
 *
19
 *-------------------------------------------------------------------------
20
 */
21
22
/**********************/
23
/* Module Declaration */
24
/**********************/
25
26
#include "H5FAmodule.h" /* This source code file is part of the H5FA module */
27
28
/***********************/
29
/* Other Packages Used */
30
/***********************/
31
32
/***********/
33
/* Headers */
34
/***********/
35
#include "H5private.h"  /* Generic Functions                */
36
#include "H5Eprivate.h" /* Error Handling                   */
37
#include "H5FApkg.h"    /* Fixed Arrays                     */
38
39
/****************/
40
/* Local Macros */
41
/****************/
42
43
/******************/
44
/* Local Typedefs */
45
/******************/
46
47
/********************/
48
/* Package Typedefs */
49
/********************/
50
51
/********************/
52
/* Local Prototypes */
53
/********************/
54
55
/*********************/
56
/* Package Variables */
57
/*********************/
58
59
/*****************************/
60
/* Library Private Variables */
61
/*****************************/
62
63
/*******************/
64
/* Local Variables */
65
/*******************/
66
67
/*-------------------------------------------------------------------------
68
 * Function:    H5FA__create_flush_depend
69
 *
70
 * Purpose:     Create a flush dependency between two data structure components
71
 *
72
 * Return:      SUCCEED/FAIL
73
 *
74
 *-------------------------------------------------------------------------
75
 */
76
herr_t
77
H5FA__create_flush_depend(H5AC_info_t *parent_entry, H5AC_info_t *child_entry)
78
0
{
79
0
    herr_t ret_value = SUCCEED; /* Return value */
80
81
0
    FUNC_ENTER_PACKAGE
82
83
    /* Sanity check */
84
0
    assert(parent_entry);
85
0
    assert(child_entry);
86
87
    /* Create a flush dependency between parent and child entry */
88
0
    if (H5AC_create_flush_dependency(parent_entry, child_entry) < 0)
89
0
        HGOTO_ERROR(H5E_FARRAY, H5E_CANTDEPEND, FAIL, "unable to create flush dependency");
90
91
0
done:
92
0
    FUNC_LEAVE_NOAPI(ret_value)
93
0
} /* end H5FA__create_flush_depend() */
94
95
/*-------------------------------------------------------------------------
96
 * Function:    H5FA__destroy_flush_depend
97
 *
98
 * Purpose:     Destroy a flush dependency between two data structure components
99
 *
100
 * Return:      SUCCEED/FAIL
101
 *
102
 *-------------------------------------------------------------------------
103
 */
104
herr_t
105
H5FA__destroy_flush_depend(H5AC_info_t *parent_entry, H5AC_info_t *child_entry)
106
0
{
107
0
    herr_t ret_value = SUCCEED; /* Return value */
108
109
0
    FUNC_ENTER_PACKAGE
110
111
    /* Sanity check */
112
0
    assert(parent_entry);
113
0
    assert(child_entry);
114
115
    /* Destroy a flush dependency between parent and child entry */
116
0
    if (H5AC_destroy_flush_dependency(parent_entry, child_entry) < 0)
117
0
        HGOTO_ERROR(H5E_FARRAY, H5E_CANTUNDEPEND, FAIL, "unable to destroy flush dependency");
118
119
0
done:
120
0
    FUNC_LEAVE_NOAPI(ret_value)
121
0
} /* end H5FA__destroy_flush_depend() */