2002-12-11 Havoc Pennington <hp@pobox.com>
[platform/upstream/dbus.git] / dbus / dbus-sysdeps.h
1 /* -*- mode: C; c-file-style: "gnu" -*- */
2 /* dbus-sysdeps.h Wrappers around system/libc features (internal to D-BUS implementation)
3  * 
4  * Copyright (C) 2002  Red Hat, Inc.
5  *
6  * Licensed under the Academic Free License version 1.2
7  * 
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  * GNU General Public License for more details.
17  * 
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
21  *
22  */
23
24 #ifndef DBUS_SYSDEPS_H
25 #define DBUS_SYSDEPS_H
26
27 #include <dbus/dbus-string.h>
28
29 /* this is perhaps bogus, but strcmp() etc. are faster if we use the
30  * stuff straight out of string.h, so have this here for now.
31  */
32 #include <string.h>
33
34 DBUS_BEGIN_DECLS;
35
36 /* The idea of this file is to encapsulate everywhere that we're
37  * relying on external libc features, for ease of security
38  * auditing. The idea is from vsftpd. This also gives us a chance to
39  * make things more convenient to use, e.g.  by reading into a
40  * DBusString. Operating system headers aren't intended to be used
41  * outside of this file and a limited number of others (such as
42  * dbus-memory.c)
43  */
44
45 void _dbus_abort (void);
46
47 const char* _dbus_getenv (const char *varname);
48
49 DBUS_END_DECLS;
50
51 #endif /* DBUS_SYSDEPS_H */