提交 5243e5f1 编写于 作者: R Rich Felker

remove obsolete and useless useconds_t type

上级 3bb00f45
...@@ -68,7 +68,6 @@ TYPEDEF long long intmax_t; ...@@ -68,7 +68,6 @@ TYPEDEF long long intmax_t;
TYPEDEF unsigned long long uintmax_t; TYPEDEF unsigned long long uintmax_t;
TYPEDEF long time_t; TYPEDEF long time_t;
TYPEDEF unsigned useconds_t;
TYPEDEF int suseconds_t; TYPEDEF int suseconds_t;
STRUCT timeval { time_t tv_sec; int tv_usec; }; STRUCT timeval { time_t tv_sec; int tv_usec; };
STRUCT timespec { time_t tv_sec; long tv_nsec; }; STRUCT timespec { time_t tv_sec; long tv_nsec; };
......
...@@ -68,7 +68,6 @@ TYPEDEF long long intmax_t; ...@@ -68,7 +68,6 @@ TYPEDEF long long intmax_t;
TYPEDEF unsigned long long uintmax_t; TYPEDEF unsigned long long uintmax_t;
TYPEDEF long time_t; TYPEDEF long time_t;
TYPEDEF long useconds_t;
TYPEDEF long suseconds_t; TYPEDEF long suseconds_t;
STRUCT timeval { time_t tv_sec; int tv_usec; }; STRUCT timeval { time_t tv_sec; int tv_usec; };
STRUCT timespec { time_t tv_sec; long tv_nsec; }; STRUCT timespec { time_t tv_sec; long tv_nsec; };
......
...@@ -29,7 +29,6 @@ extern "C" { ...@@ -29,7 +29,6 @@ extern "C" {
#define __NEED_gid_t #define __NEED_gid_t
#define __NEED_off_t #define __NEED_off_t
#define __NEED_pid_t #define __NEED_pid_t
#define __NEED_useconds_t
#define __NEED_intptr_t #define __NEED_intptr_t
#include <bits/alltypes.h> #include <bits/alltypes.h>
...@@ -152,8 +151,8 @@ int vhangup(void); ...@@ -152,8 +151,8 @@ int vhangup(void);
int chroot(const char *); int chroot(const char *);
int getpagesize(void); int getpagesize(void);
int sethostname(const char *, size_t); int sethostname(const char *, size_t);
int usleep(useconds_t); int usleep(unsigned);
useconds_t ualarm(useconds_t, useconds_t); unsigned ualarm(unsigned, unsigned);
int setgroups(int, const gid_t []); int setgroups(int, const gid_t []);
#endif #endif
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
#include "syscall.h" #include "syscall.h"
/* FIXME: ?? */ /* FIXME: ?? */
useconds_t ualarm(useconds_t useconds, useconds_t interval) unsigned ualarm(unsigned useconds, unsigned interval)
{ {
return -1; return -1;
} }
#include <unistd.h> #include <unistd.h>
#include <time.h> #include <time.h>
int usleep(useconds_t useconds) int usleep(unsigned useconds)
{ {
struct timespec tv = { struct timespec tv = {
.tv_sec = useconds/1000000, .tv_sec = useconds/1000000,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册