summaryrefslogtreecommitdiffstats
path: root/src/H5Ounknown.c
blob: 89c00ada326381d80ac048e308700505e0af3807 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
 * Copyright by The HDF Group.                                               *
 * Copyright by the Board of Trustees of the University of Illinois.         *
 * All rights reserved.                                                      *
 *                                                                           *
 * This file is part of HDF5.  The full HDF5 copyright notice, including     *
 * terms governing use, modification, and redistribution, is contained in    *
 * the COPYING file, which can be found at the root of the source code       *
 * distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases.  *
 * If you do not have access to either file, you may request a copy from     *
 * help@hdfgroup.org.                                                        *
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

/*-------------------------------------------------------------------------
 *
 * Created:             H5Ounknown.c
 *                      Apr 19 2007
 *                      Quincey Koziol <koziol@hdfgroup.org>
 *
 * Purpose:             Handle unknown message classes in a minimal way.
 *
 *-------------------------------------------------------------------------
 */

#include "H5Omodule.h"          /* This source code file is part of the H5O module */


#include "H5private.h"		/* Generic Functions			*/
#include "H5Eprivate.h"		/* Error handling		  	*/
#include "H5FLprivate.h"	/* Free lists                           */
#include "H5Opkg.h"             /* Object headers			*/


/* PRIVATE PROTOTYPES */
static herr_t H5O__unknown_free(void *_mesg);

/* This message derives from H5O message class */
const H5O_msg_class_t H5O_MSG_UNKNOWN[1] = {{
    H5O_UNKNOWN_ID,           	/*message id number             */
    "unknown",                	/*message name for debugging    */
    0,				/*native message size           */
    0,			        /* messages are sharable?       */
    NULL,			/*decode message                */
    NULL,			/*encode message                */
    NULL,			/*copy the native value         */
    NULL,			/*size of symbol table entry    */
    NULL,                   	/*default reset method          */
    H5O__unknown_free,	        /* free method			*/
    NULL,			/* file delete method		*/
    NULL,			/* link method			*/
    NULL, 			/*set share method		*/
    NULL,		    	/*can share method		*/
    NULL,			/* pre copy native value to file */
    NULL,			/* copy native value to file    */
    NULL,			/* post copy native value to file */
    NULL,			/* get creation index		*/
    NULL,			/* set creation index		*/
    NULL			/*debug the message             */
}};

/* Declare a free list to manage the H5O_unknown_t struct */
H5FL_DEFINE(H5O_unknown_t);


/*-------------------------------------------------------------------------
 * Function:    H5O__unknown_free
 *
 * Purpose:     Frees the message
 *
 * Return:      SUCCEED/FAIL
 *
 * Programmer:	Quincey Koziol
 *              Tuesday, May 1, 2007
 *
 *-------------------------------------------------------------------------
 */
static herr_t
H5O__unknown_free(void *mesg)
{
    FUNC_ENTER_STATIC_NOERR

    HDassert(mesg);

    mesg = H5FL_FREE(H5O_unknown_t, mesg);

    FUNC_LEAVE_NOAPI(SUCCEED)
} /* end H5O__unknown_free() */