~ubuntu-branches/debian/sid/rlinetd/sid

« back to all changes in this revision

Viewing changes to src/assemble.h

  • Committer: Bazaar Package Importer
  • Author(s): Robert Luberda
  • Date: 2010-03-20 18:03:45 UTC
  • mfrom: (2.3.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20100320180345-x1srfbe2tg00ezsf
Tags: 0.7-1
* New upstream version.
* Recommend rsyslog instead of sysklogd (closes: #526922).
* update-inetd:
  + add support for enabling, disabling and removing entries;
  + use ucf for managing generated files;
  + ignore ucf files in rlinetd.conf;
  + make appropriate changes in  postinst and postrm scripts.
* Set debhelper compat level to 7
* Standards-Version: 3.8.4 (no changes). 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef H_ASSEMBLE
 
2
#define H_ASSEMBLE
 
3
 
 
4
#include "rlinetd.h"
 
5
 
 
6
struct array {
 
7
#ifdef MEMDEBUG
 
8
        char *id;
 
9
#endif  
 
10
        rl_opcode_t *elems;
 
11
        int len;
 
12
};
 
13
 
 
14
struct optab {
 
15
        rl_opcode_t opcode;
 
16
        int nargs;
 
17
        struct array *after;
 
18
};
 
19
 
 
20
typedef enum { ofp_none = 0,
 
21
        ofp_iname,      /* stringtab for service name */
 
22
        ofp_exec,       /* stringtab for program to exec */
 
23
        ofp_parent,     /* oplist for parent to exec post-fork */
 
24
        ofp_iuser,      /* stringtab for username */
 
25
        
 
26
        ofp_setuid,             /* user id */
 
27
        ofp_supgid,             /* supplementary groupid for initgroups */
 
28
        ofp_setgid,             /* primary group */
 
29
        ofp_onexit,     /* opstream to run when child exits */
 
30
                                                   ofp_max_fixups
 
31
                                                 } opmeta_fixup_ptr;
 
32
 
 
33
struct opmeta {
 
34
#ifdef MEMDEBUG
 
35
        char *id;
 
36
#endif  
 
37
        int len;
 
38
        rl_opcode_t *bytes;
 
39
        struct array *after;
 
40
        struct array *ops;
 
41
        opmeta_fixup_ptr *fixup;
 
42
};
 
43
 
 
44
struct opmetalist {
 
45
#ifdef MEMDEBUG
 
46
        char *id;
 
47
#endif  
 
48
        int len;
 
49
        struct opmeta **opms;
 
50
};
 
51
 
 
52
 
 
53
struct opmeta *opmeta_make(int, rl_opcode_t, ...);
 
54
int opmetalist_add(struct opmetalist *, struct opmeta *);
 
55
struct opmetalist *opmetalist_merge(struct opmetalist *o, const struct opmetalist *p);
 
56
struct opmetalist *opmetalist_join(struct opmetalist *, struct opmetalist *);
 
57
void opmeta_fixup(struct opmeta *, int, opmeta_fixup_ptr);
 
58
struct opmetalist *opmetalist_new();
 
59
struct oplist *opmetalist_resolve(struct opmetalist *, const opmeta_fixup_ptr[]);
 
60
void opmetalist_free(struct opmetalist *);
 
61
 
 
62
#endif /* !H_ASSEMBLE */
 
63
 
 
64
/* vim: set ts=2: */