~ubuntu-branches/ubuntu/trusty/clamsmtp/trusty

« back to all changes in this revision

Viewing changes to common/compat.h

  • Committer: Bazaar Package Importer
  • Author(s): Chad Walstrom
  • Date: 2007-03-16 12:18:21 UTC
  • mfrom: (2.1.4 feisty)
  • Revision ID: james.westby@ubuntu.com-20070316121821-68pr5njlmsonuigy
Tags: 1.8-5
* debian/postinst: A few logic errors found and fixed.  Moved checks to add
  clamav user to clamsmtp group outside scope of clamsmtp user/group test.
  Upon install or reinstall, only restart clamav-daemon if clamav user is
  added to the clamsmtp group.  Truly Closes: #413968.
* debian/postrm: Encapsulated invoke-rc.d calls to start and stop
  clamav-daemon in a sub-shell.  If we cannot stop the service, we shouldn't
  try to start it.

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
#endif
45
45
 
46
46
#include <sys/types.h>
 
47
#include <stdlib.h>
47
48
 
48
49
#ifndef HAVE_STDARG_H
49
50
#error ERROR: Must have a working stdarg.h header
51
52
#include <stdarg.h>
52
53
#endif
53
54
 
 
55
#ifdef WITH_DMALLOC
 
56
#include "dmalloc.h"
 
57
#endif
 
58
 
54
59
#ifndef HAVE_REALLOCF
55
60
void* reallocf(void* p, size_t sz);
56
61
#endif
83
88
size_t strlcpy(char *dst, const char *src, size_t size);
84
89
#endif
85
90
 
 
91
#ifndef HAVE_SETENV
 
92
int setenv(const char* name, const char* value, int overwrite);
 
93
#endif
 
94
 
 
95
#ifndef HAVE_DAEMON
 
96
int daemon(int nochdir, int noclose);
 
97
#endif
 
98
 
 
99
#ifndef HAVE_GETLINE
 
100
ssize_t getline(char** lineptr, size_t* n, FILE* stream);
 
101
#endif
 
102
 
 
103
#ifndef HAVE_GETDELIM
 
104
ssize_t getdelim(char** lineptr, size_t* n, int delim, FILE* stream);
 
105
#endif
 
106
 
 
107
#ifdef HAVE_ERR_H
 
108
#include <err.h>
 
109
#else
 
110
#include <stdarg.h>
 
111
void err_set_file(void *fp);
 
112
void err_set_exit(void (*ef)(int));
 
113
void err(int eval, const char *fmt, ...);
 
114
void verr(int eval, const char *fmt, va_list ap);
 
115
void errc(int eval, int code, const char *fmt, ...);
 
116
void verrc(int eval, int code, const char *fmt, va_list ap);
 
117
void errx(int eval, const char *fmt, ...);
 
118
void verrx(int eval, const char *fmt, va_list ap);
 
119
void warn(const char *fmt, ...);
 
120
void vwarn(const char *fmt, va_list ap);
 
121
void warnc(int code, const char *fmt, ...);
 
122
void vwarnc(int code, const char *fmt, va_list ap);
 
123
void warnx(const char *fmt, ...);
 
124
void vwarnx(const char *fmt, va_list ap);
 
125
#endif
 
126
 
 
127
#ifdef HAVE_PATHS_H
 
128
#include <paths.h>
 
129
#endif
 
130
 
 
131
#ifndef _PATH_DEVNULL
 
132
#define _PATH_DEVNULL "/dev/null"
 
133
#endif
 
134
 
 
135
#ifndef _PATH_TMP
 
136
#define _PATH_TMP "/tmp"
 
137
#endif
 
138
 
86
139
#endif /* _COMPAT_H_ */