compat.c revision 9f9dc85ef78dd2f431da00f26d292a0ed4f07350
/* Copyright (c) 2002-2003 Timo Sirainen */
#include "config.h"
#ifdef PREAD_WRAPPERS
#endif
#define IN_COMPAT_C
#include "lib.h"
#include <stdio.h>
#include <ctype.h>
#include <unistd.h>
#include <syslog.h>
#ifndef INADDR_NONE
# define INADDR_NONE INADDR_BROADCAST
#endif
#if !defined (HAVE_STRCASECMP) && !defined (HAVE_STRICMP)
{
}
}
{
}
}
#endif
#ifndef HAVE_INET_ATON
{
if (addr == INADDR_NONE)
return 0;
return 1;
}
#endif
#ifndef HAVE_VSYSLOG
{
t_push();
t_pop();
}
#endif
#ifndef HAVE_GETPAGESIZE
int my_getpagesize(void)
{
#ifdef _SC_PAGESIZE
return sysconf(_SC_PAGESIZE);
#else
# ifdef __GNUC__
# endif
return 4096;
#endif
}
#endif
#ifndef HAVE_WRITEV
{
int i;
written = 0;
if (ret < 0)
return -1;
break;
}
if (written > SSIZE_T_MAX) {
return -1;
}
}
#endif
#ifndef HAVE_PREAD
{
if (old_offset == -1)
return -1;
return -1;
if (ret < 0)
return -1;
return -1;
return ret;
}
{
if (old_offset == -1)
return -1;
return -1;
if (ret < 0)
return -1;
return -1;
return ret;
}
#endif
#ifdef PREAD_WRAPPERS
{
}
{
}
#endif
#ifndef HAVE_SETEUID
{
#ifdef HAVE_SETREUID
/* HP-UX at least doesn't have seteuid() but has setreuid() */
#else
#endif
}
#endif