s3-prefork: Improve error detection when handling new connections
[amitay/samba.git] / source3 / registry / reg_backend_db.h
1 /* 
2  *  Unix SMB/CIFS implementation.
3  *  Virtual Windows Registry Layer
4  *  Copyright (C) Gerald Carter                     2002-2005
5  *  Copyright (C) Michael Adam                      2007-2009
6  *
7  *  This program is free software; you can redistribute it and/or modify
8  *  it under the terms of the GNU General Public License as published by
9  *  the Free Software Foundation; either version 3 of the License, or
10  *  (at your option) any later version.
11  *  
12  *  This program is distributed in the hope that it will be useful,
13  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  *  GNU General Public License for more details.
16  *  
17  *  You should have received a copy of the GNU General Public License
18  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
19  */
20
21 #ifndef _REG_BACKEND_DB_H
22 #define _REG_BACKEND_DB_H
23
24 #include "registry.h"
25
26 WERROR init_registry_key(const char *add_path);
27 WERROR init_registry_data(void);
28 WERROR regdb_init(void);
29 WERROR regdb_open( void );
30 int regdb_close( void );
31 WERROR regdb_transaction_start(void);
32 WERROR regdb_transaction_commit(void);
33 WERROR regdb_transaction_cancel(void);
34 int regdb_get_seqnum(void);
35 bool regdb_store_keys(const char *key, struct regsubkey_ctr *ctr);
36 int regdb_fetch_keys(const char *key, struct regsubkey_ctr *ctr);
37 int regdb_fetch_values(const char* key, struct regval_ctr *values);
38 bool regdb_store_values(const char *key, struct regval_ctr *values);
39 bool regdb_subkeys_need_update(struct regsubkey_ctr *subkeys);
40 bool regdb_values_need_update(struct regval_ctr *values);
41
42 #endif /* _REG_BACKEND_DB_H */