2006-11-28 04:23:22 +08:00
|
|
|
/*
|
|
|
|
* dhcpcd - DHCP client daemon -
|
2007-01-17 01:54:07 +08:00
|
|
|
* Copyright 2006-2007 Roy Marples <uberlord@gentoo.org>
|
2006-11-28 04:23:22 +08:00
|
|
|
*
|
|
|
|
* dhcpcd is an RFC2131 compliant DHCP client daemon.
|
|
|
|
*
|
|
|
|
* This is free software; you can redistribute it and/or modify it
|
|
|
|
* under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful, but
|
|
|
|
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
* See the GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef COMMON_H
|
|
|
|
#define COMMON_H
|
|
|
|
|
2007-04-06 02:11:05 +08:00
|
|
|
/* string.h pulls in features.h so the below define checks work */
|
|
|
|
#include <string.h>
|
|
|
|
|
2007-04-06 02:05:38 +08:00
|
|
|
/* Only GLIBC doesn't support strlcpy */
|
2007-04-06 01:31:05 +08:00
|
|
|
#ifdef __GLIBC__
|
2007-04-06 02:05:38 +08:00
|
|
|
# if ! defined(__UCLIBC__) && ! defined (__dietlibc__)
|
2007-04-06 01:31:05 +08:00
|
|
|
size_t strlcpy (char *dst, const char *src, size_t size);
|
2007-04-06 02:05:38 +08:00
|
|
|
# endif
|
2007-04-06 01:31:05 +08:00
|
|
|
#endif
|
|
|
|
|
2006-11-28 04:23:22 +08:00
|
|
|
long uptime (void);
|
|
|
|
void *xmalloc (size_t size);
|
2007-04-27 00:16:56 +08:00
|
|
|
char *xstrdup (const char *str);
|
2007-04-06 00:56:58 +08:00
|
|
|
|
2006-11-28 04:23:22 +08:00
|
|
|
#endif
|