Fix FreeBSD build.
[haiku.git] / headers / os / net / net_settings.h
blobb2ef40e3ea4f82e97325070cb7db564807a49825
1 /*
2 * Copyright 2009, Haiku, Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef _NET_SETTINGS_H
6 #define _NET_SETTINGS_H
9 #include <SupportDefs.h>
11 #if __cplusplus
12 extern "C" {
13 #endif /* __cplusplus */
16 /* private types */
17 typedef struct _ns_entry {
18 const char* key;
19 const char* value;
20 } _ns_entry_t;
22 typedef struct _ns_section {
23 const char* heading;
24 unsigned nentries;
25 _ns_entry_t* entries;
26 } _ns_section_t;
29 /* public type (data members are private) */
30 typedef struct _net_settings {
31 int _dirty;
32 unsigned _nsections;
33 _ns_section_t* _sections;
34 char _fname[64];
35 } net_settings;
37 /* finding and setting network preferences */
38 extern char* find_net_setting(net_settings* ncw, const char* heading,
39 const char* name, char* value, unsigned nbytes);
41 extern status_t set_net_setting(net_settings* ncw, const char* heading,
42 const char* name, const char* value);
45 #if __cplusplus
47 #endif /* __cplusplus */
49 #endif /* _NET_SETTINGS_H */