syslog-ng source
getent-generic.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017 Balabit
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17  *
18  * As an additional exemption you are allowed to compile & link against the
19  * OpenSSL libraries as published by the OpenSSL project. See the file
20  * COPYING for details.
21  *
22  */
23 
24 #ifndef COMPAT_GETENT_GENERIC_H_INCLUDED
25 #define COMPAT_GETENT_GENERIC_H_INCLUDED
26 
27 #include "compat/compat.h"
28 
29 #if ! SYSLOG_NG_HAVE_GETPROTOBYNUMBER_R
30 
31 #include <sys/types.h>
32 #include <grp.h>
33 #include <pwd.h>
34 #include <netdb.h>
35 
37  struct protoent *result_buf, char *buf,
38  size_t buflen, struct protoent **result);
39 
41  struct protoent *result_buf, char *buf,
42  size_t buflen, struct protoent **result);
43 
44 int _compat_generic__getservbyport_r(int port, const char *proto,
45  struct servent *result_buf, char *buf,
46  size_t buflen, struct servent **result);
47 
48 int _compat_generic__getservbyname_r(const char *name, const char *proto,
49  struct servent *result_buf, char *buf,
50  size_t buflen, struct servent **result);
51 
52 #endif
53 
54 #endif
const gchar * name
Definition: debugger.c:265
int _compat_generic__getservbyport_r(int port, const char *proto, struct servent *result_buf, char *buf, size_t buflen, struct servent **result)
Definition: getent-generic.c:109
int _compat_generic__getprotobynumber_r(int proto, struct protoent *result_buf, char *buf, size_t buflen, struct protoent **result)
Definition: getent-generic.c:48
int _compat_generic__getprotobyname_r(const char *name, struct protoent *result_buf, char *buf, size_t buflen, struct protoent **result)
Definition: getent-generic.c:69
int _compat_generic__getservbyname_r(const char *name, const char *proto, struct servent *result_buf, char *buf, size_t buflen, struct servent **result)
Definition: getent-generic.c:130
GString * result
Definition: test_lexer_block.c:34