Skip to content

Commit db819ef

Browse files
committed
Clean up
1 parent 561b28a commit db819ef

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

configure.ac

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,11 +91,11 @@ AC_CHECK_HEADERS(unistd.h \
9191
netinet/in_systm.h \
9292
arpa/inet.h \
9393
sys/ioctl.h \
94-
memory.h \
9594
setjmp.h \
9695
errno.h \
9796
strcasecmp.h \
98-
fcntl.h
97+
fcntl.h \
98+
grp.h
9999
)
100100

101101

@@ -136,7 +136,7 @@ if test "$ac_cv_func_fnmatch_gnu" = "yes"; then
136136
[Define if you have a fnmatch supporting GNU extensions])
137137
fi
138138

139-
AC_CHECK_FUNCS(strcoll memcpy sigsetjmp)
139+
AC_CHECK_FUNCS(sigsetjmp)
140140
AC_CHECK_FUNCS(vasprintf, [], [AC_LIBOBJ([vasprintf])])
141141
AC_CHECK_DECLS([asprintf, vasprintf])
142142

lib/security.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ static int sec_get_data(int fd, struct buffer *buf, int level)
151151

152152
static size_t buffer_read(struct buffer *buf, void *data, size_t len)
153153
{
154-
len = min(len, buf->size - buf->index);
154+
len = MIN(len, buf->size - buf->index);
155155
memcpy(data, (char *)buf->data + buf->index, len);
156156
buf->index += len;
157157
return len;

src/syshdr.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,24 +47,19 @@
4747
#include <string.h>
4848
#include <stdlib.h>
4949

50-
5150
#include <ctype.h>
5251
#include <signal.h>
5352
#include <stdarg.h>
5453
#include <setjmp.h>
5554

5655
#include <errno.h>
57-
#include <grp.h>
5856

5957
#include "libmhe/xmalloc.h"
6058

6159
#include <sys/ioctl.h>
6260

63-
#if defined HAVE_DECL_ASPRINTF && !HAVE_DECL_ASPRINTF
64-
int asprintf(char **strp, const char *format, ...) YAFC_PRINTF(2, 3);
65-
#endif
66-
#if defined HAVE_DECL_VASPRINTF && !HAVE_DECL_VASPRINTF
67-
int vasprintf(char **strp, const char *format, va_list ap);
61+
#ifdef HAVE_GRP_H
62+
# include <grp.h>
6863
#endif
6964

7065
#ifdef HAVE_UNISTD_H
@@ -181,7 +176,12 @@ typedef CPPFunction rl_completion_func_t;
181176
# include "../lib/getopt.h" /* our own, in lib/ */
182177
#endif
183178

184-
#define min(a, b) ((a) < (b) ? (a) : (b))
179+
#if defined HAVE_DECL_ASPRINTF && !HAVE_DECL_ASPRINTF
180+
int asprintf(char **strp, const char *format, ...) YAFC_PRINTF(2, 3);
181+
#endif
182+
#if defined HAVE_DECL_VASPRINTF && !HAVE_DECL_VASPRINTF
183+
int vasprintf(char **strp, const char *format, va_list ap);
184+
#endif
185185

186186
#ifdef HAVE_KERBEROS
187187
# define SECFTP

0 commit comments

Comments
 (0)