#ifdef HAVE_CONFIG_H
# include "config.h"
#endif

#ifndef HAVE_USLEEP

#ifndef lint
static char RCSid[] = "$Id: usleep.c,v 1.1 1996/09/24 07:47:33 sjg Exp $";
#endif
#include <sys/types.h>
#include <sys/time.h>
#ifdef HAVE_SYS_SELECT_H
# include <sys/select.h>
#endif

int
usleep(usec)
	unsigned int usec;
{
	struct timeval tv;

	tv.tv_sec = 0;
	tv.tv_usec = usec;

	(void) select(1, NULL, NULL, NULL, &tv);
	return 0;
}
#endif
