]>
git.ipfire.org Git - people/mfischer/ipfire-2.x.git/blob - src/libsmooth/libsmooth.h
1 /* SmoothWall libsmooth.
3 * This program is distributed under the terms of the GNU General Public
4 * Licence. See the file COPYING for details.
6 * (c) Lawrence Manning, 2001
7 * Contains prototypes for library functions.
11 #ifndef ___LIBSMOOTH_H
12 #define ___LIBSMOOTH_H
22 #include <sys/types.h>
27 #include <sys/mount.h>
29 #include <sys/socket.h>
30 #include <netinet/in.h>
31 #include <arpa/inet.h>
33 #include <linux/cdrom.h>
34 #include <sys/ioctl.h>
36 #define STRING_SIZE 1024
39 char key
[STRING_SIZE
];
40 char value
[STRING_SIZE
];
41 struct keyvalue
*next
;
45 void stripnl(char *s
);
46 int mysystem(const char* output
, const char *command
);
47 void errorbox(char *message
);
48 int statuswindowscroll(int width
, int height
, const char *title
, const char *text
, ...);
49 int disclaimerbox(char *message
);
50 void statuswindow(int width
, int height
, const char *title
, const char *text
, ...);
51 int runcommandwithprogress(int width
, int height
, const char *title
, const char *command
,
52 int lines
, char *text
, ...);
53 int runcommandwithstatus(const char *command
, const char* title
, const char *message
, const char* output
);
54 int runhiddencommandwithstatus(const char *command
, const char* title
, const char *message
, const char* output
);
55 int splashWindow(const char* title
, const char* message
, unsigned int timeout
);
56 int checkformodule(const char *module
);
57 int replace(char filename1
[], char *from
, char *to
);
58 char* get_version(void);
61 struct keyvalue
*initkeyvalues(void);
62 void freekeyvalues(struct keyvalue
*head
);
63 int readkeyvalues(struct keyvalue
*head
, char *filename
);
64 int writekeyvalues(struct keyvalue
*head
, char *filename
);
65 int findkey(struct keyvalue
*head
, char *key
, char *value
);
66 void appendkeyvalue(struct keyvalue
*head
, char *key
, char *value
);
67 void replacekeyvalue(struct keyvalue
*head
, char *key
, char *value
);