1 /* $NetBSD: dlz_drivers.c,v 1.5 2014/12/10 04:37:55 christos Exp $ */
4 * Copyright (C) 2005 Internet Systems Consortium, Inc. ("ISC")
6 * Permission to use, copy, modify, and distribute this software for any
7 * purpose with or without fee is hereby granted, provided that the above
8 * copyright notice and this permission notice appear in all copies.
10 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
11 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
12 * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
13 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
14 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
15 * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16 * PERFORMANCE OF THIS SOFTWARE.
19 /* Id: dlz_drivers.c,v 1.4 2011/03/10 04:36:16 each Exp */
25 #include <isc/result.h>
28 * Pull in declarations for this module's functions.
31 #include <dlz/dlz_drivers.h>
34 * Pull in driver-specific stuff.
38 #include <dlz/dlz_stub_driver.h>
42 #include <dlz/dlz_postgres_driver.h>
46 #include <dlz/dlz_mysql_driver.h>
50 #include <dlz/dlz_filesystem_driver.h>
54 #include <dlz/dlz_bdb_driver.h>
55 #include <dlz/dlz_bdbhpt_driver.h>
59 #include <dlz/dlz_ldap_driver.h>
63 #include <dlz/dlz_odbc_driver.h>
67 * Call init functions for all relevant DLZ drivers.
71 dlz_drivers_init(void) {
73 isc_result_t result
= ISC_R_SUCCESS
;
76 result
= dlz_stub_init();
77 if (result
!= ISC_R_SUCCESS
)
82 result
= dlz_postgres_init();
83 if (result
!= ISC_R_SUCCESS
)
88 result
= dlz_mysql_init();
89 if (result
!= ISC_R_SUCCESS
)
94 result
= dlz_fs_init();
95 if (result
!= ISC_R_SUCCESS
)
100 result
= dlz_bdb_init();
101 if (result
!= ISC_R_SUCCESS
)
103 result
= dlz_bdbhpt_init();
104 if (result
!= ISC_R_SUCCESS
)
109 result
= dlz_ldap_init();
110 if (result
!= ISC_R_SUCCESS
)
115 result
= dlz_odbc_init();
116 if (result
!= ISC_R_SUCCESS
)
124 * Call shutdown functions for all relevant DLZ drivers.
128 dlz_drivers_clear(void) {
135 dlz_postgres_clear();
142 #ifdef DLZ_FILESYSTEM