mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:17:44 +00:00
Lots of minor compat stuff while seeing if bash would build.
We're quite far from bash building, but we'll get there eventually!
This commit is contained in:
parent
e4611248c4
commit
e76312ab63
21 changed files with 172 additions and 38 deletions
|
@ -6,13 +6,14 @@ extern "C" {
|
|||
|
||||
time_t time(time_t* tloc)
|
||||
{
|
||||
timeval tv;
|
||||
if (gettimeofday(&tv) < 0)
|
||||
struct timeval tv;
|
||||
struct timezone tz;
|
||||
if (gettimeofday(&tv, &tz) < 0)
|
||||
return (time_t)-1;
|
||||
return tv.tv_sec;
|
||||
}
|
||||
|
||||
int gettimeofday(timeval* tv)
|
||||
int gettimeofday(struct timeval* tv, struct timezone*)
|
||||
{
|
||||
int rc = Syscall::invoke(Syscall::PosixGettimeofday, (dword)tv);
|
||||
__RETURN_WITH_ERRNO(rc, rc, -1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue