Move declarations of compat functions from ircaux.h to irc_std.h
irc_std.h is where these belong - it's where the normal declarations (via the system headers) come from on systems which don't need the compat functions.
This commit is contained in:
@@ -9,9 +9,9 @@
|
|||||||
*
|
*
|
||||||
* @(#)$Id$
|
* @(#)$Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef IRC_STD_H_
|
#ifndef IRC_STD_H_
|
||||||
#define IRC_STD_H_
|
#define IRC_STD_H_
|
||||||
|
|
||||||
#include "defs.h"
|
#include "defs.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -259,4 +259,46 @@ int ioctl (int, int, ...);
|
|||||||
#if !HAVE_DECL_SYS_SIGLIST && HAVE_DECL__SYS_SIGLIST
|
#if !HAVE_DECL_SYS_SIGLIST && HAVE_DECL__SYS_SIGLIST
|
||||||
#define sys_siglist _sys_siglist
|
#define sys_siglist _sys_siglist
|
||||||
#endif
|
#endif
|
||||||
#endif /* __irc_std_h */
|
|
||||||
|
/* Used in compat.c */
|
||||||
|
#ifndef HAVE_TPARM
|
||||||
|
char *tparm (const char *, ...);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_STRTOUL
|
||||||
|
unsigned long strtoul (const char *, char **, int);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_SETENV
|
||||||
|
char * bsd_getenv (const char *);
|
||||||
|
int bsd_putenv (const char *);
|
||||||
|
int bsd_setenv (const char *, const char *, int);
|
||||||
|
void bsd_unsetenv (const char *);
|
||||||
|
#define setenv bsd_setenv
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_INET_ATON
|
||||||
|
int inet_aton (const char *, struct in_addr *);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_STRLCPY
|
||||||
|
size_t strlcpy (char *, const char *, size_t);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_STRLCAT
|
||||||
|
size_t strlcat (char *, const char *, size_t);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_VSNPRINTF
|
||||||
|
int vsnprintf (char *, size_t, const char *, va_list);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_SNPRINTF
|
||||||
|
int snprintf (char *, size_t, const char *, ...);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_SETSID
|
||||||
|
int setsid (void);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif /* IRC_STD_H_ */
|
||||||
|
|||||||
@@ -9,20 +9,17 @@
|
|||||||
*
|
*
|
||||||
* @(#)$Id$
|
* @(#)$Id$
|
||||||
*/
|
*/
|
||||||
|
#ifndef IRCAUX_H_
|
||||||
#ifndef _IRCAUX_H_
|
#define IRCAUX_H_
|
||||||
#define _IRCAUX_H_
|
|
||||||
|
|
||||||
#include "irc.h"
|
#include "irc.h"
|
||||||
#include "irc_std.h"
|
#include "irc_std.h"
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
typedef int comp_len_func (char *, char *, int);
|
typedef int comp_len_func (char *, char *, int);
|
||||||
typedef int comp_func (char *, char *);
|
typedef int comp_func (char *, char *);
|
||||||
|
|
||||||
extern unsigned char stricmp_table[];
|
extern unsigned char stricmp_table[];
|
||||||
|
|
||||||
|
|
||||||
char * BX_check_nickname (char *);
|
char * BX_check_nickname (char *);
|
||||||
char * BX_next_arg (char *, char **);
|
char * BX_next_arg (char *, char **);
|
||||||
char * BX_new_next_arg (char *, char **);
|
char * BX_new_next_arg (char *, char **);
|
||||||
@@ -53,13 +50,8 @@ char * BX_m_sprintf (const char *, ...);
|
|||||||
int BX_is_number (const char *);
|
int BX_is_number (const char *);
|
||||||
char * BX_my_ctime (time_t);
|
char * BX_my_ctime (time_t);
|
||||||
|
|
||||||
#if 0
|
|
||||||
#define my_stricmp(x, y) strcasecmp(x, y) /* unable to use these for reasons of case sensitivity and finish */
|
|
||||||
#define my_strnicmp(x, y, n) strncasecmp(x, y, n)
|
|
||||||
#else
|
|
||||||
int BX_my_stricmp (const char *, const char *);
|
int BX_my_stricmp (const char *, const char *);
|
||||||
int BX_my_strnicmp (const char *, const char *, size_t);
|
int BX_my_strnicmp (const char *, const char *, size_t);
|
||||||
#endif
|
|
||||||
|
|
||||||
int BX_my_strnstr (const char *, const char *, size_t);
|
int BX_my_strnstr (const char *, const char *, size_t);
|
||||||
int BX_scanstr (char *, char *);
|
int BX_scanstr (char *, char *);
|
||||||
@@ -252,45 +244,4 @@ char *ulongcomma (unsigned long);
|
|||||||
|
|
||||||
#define SAFE(x) (((x) && *(x)) ? (x) : empty_string)
|
#define SAFE(x) (((x) && *(x)) ? (x) : empty_string)
|
||||||
|
|
||||||
/* Used in compat.c */
|
#endif /* IRCAUX_H_ */
|
||||||
#ifndef HAVE_TPARM
|
|
||||||
char *tparm (const char *, ...);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_STRTOUL
|
|
||||||
unsigned long strtoul (const char *, char **, int);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_SETENV
|
|
||||||
char * bsd_getenv (const char *);
|
|
||||||
int bsd_putenv (const char *);
|
|
||||||
int bsd_setenv (const char *, const char *, int);
|
|
||||||
void bsd_unsetenv (const char *);
|
|
||||||
#define setenv bsd_setenv
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_INET_ATON
|
|
||||||
int inet_aton (const char *, struct in_addr *);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_STRLCPY
|
|
||||||
size_t strlcpy (char *, const char *, size_t);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_STRLCAT
|
|
||||||
size_t strlcat (char *, const char *, size_t);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_VSNPRINTF
|
|
||||||
int vsnprintf (char *, size_t, const char *, va_list);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_SNPRINTF
|
|
||||||
int snprintf (char *, size_t, const char *, ...);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef HAVE_SETSID
|
|
||||||
int setsid (void);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif /* _IRCAUX_H_ */
|
|
||||||
|
|||||||
@@ -7,8 +7,6 @@
|
|||||||
* going to hurt my feelings if you re-use this.
|
* going to hurt my feelings if you re-use this.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "defs.h"
|
|
||||||
#include "ircaux.h"
|
|
||||||
#include "irc_std.h"
|
#include "irc_std.h"
|
||||||
|
|
||||||
/* --- start of tparm.c --- */
|
/* --- start of tparm.c --- */
|
||||||
|
|||||||
Reference in New Issue
Block a user