]> git.ipfire.org Git - thirdparty/e2fsprogs.git/blame - lib/ss/ss.h
Many files:
[thirdparty/e2fsprogs.git] / lib / ss / ss.h
CommitLineData
3839e657
TT
1/*
2 * Copyright 1987, 1988 by MIT Student Information Processing Board
3 *
4 * For copyright information, see mit-sipb-copyright.h.
5 */
6
7#ifndef _ss_h
8#define _ss_h __FILE__
9
10#include <ss/mit-sipb-copyright.h>
11#include <ss/ss_err.h>
12
13extern int errno;
14
15#ifdef __STDC__
16#define __SS_CONST const
17#define __SS_PROTO (int, const char * const *, int, void *)
18#else
19#define __SS_CONST
20#define __SS_PROTO ()
21#endif
22
23typedef __SS_CONST struct _ss_request_entry {
24 __SS_CONST char * __SS_CONST *command_names; /* whatever */
25 void (* __SS_CONST function) __SS_PROTO; /* foo */
26 __SS_CONST char * __SS_CONST info_string; /* NULL */
27 int flags; /* 0 */
28} ss_request_entry;
29
30typedef __SS_CONST struct _ss_request_table {
31 int version;
32 ss_request_entry *requests;
33} ss_request_table;
34
35#define SS_RQT_TBL_V2 2
36
37typedef struct _ss_rp_options { /* DEFAULT VALUES */
38 int version; /* SS_RP_V1 */
39 void (*unknown) __SS_PROTO; /* call for unknown command */
40 int allow_suspend;
41 int catch_int;
42} ss_rp_options;
43
44#define SS_RP_V1 1
45
46#define SS_OPT_DONT_LIST 0x0001
47#define SS_OPT_DONT_SUMMARIZE 0x0002
48
49void ss_help __SS_PROTO;
f3db3566
TT
50#if 0
51char *ss_current_request(); /* This is actually a macro */
52#endif
3839e657 53#ifdef __STDC__
f3db3566 54char *ss_name(int sci_idx);
3839e657
TT
55void ss_error (int, long, char const *, ...);
56void ss_perror (int, long, char const *);
57int ss_create_invocation(char *, char *, char *, ss_request_table *, int *);
58void ss_delete_invocation(int);
59int ss_listen(int);
60void ss_add_request_table(int, ss_request_table *, int, int *);
61void ss_delete_request_table(int, ss_request_table *, int *);
f3db3566 62void ss_abort_subsystem(int sci_idx, int code);
3839e657 63#else
f3db3566 64char *ss_name();
3839e657
TT
65void ss_error ();
66void ss_perror ();
67int ss_create_invocation();
68void ss_delete_invocation();
69int ss_listen();
70void ss_add_request_table();
71void ss_delete_request_table();
3839e657 72void ss_abort_subsystem();
f3db3566 73#endif
3839e657
TT
74extern ss_request_table ss_std_requests;
75#endif /* _ss_h */