mirror of
https://github.com/pspdev/pspsdk.git
synced 2025-12-31 12:47:32 +00:00
Fix wrong struct used for timeval. Newlib expects 64bits for seconds and PSP expects 32
This commit is contained in:
@@ -30,6 +30,15 @@ extern "C" {
|
||||
|
||||
#include <sys/time.h>
|
||||
|
||||
/**
|
||||
* This struct is needed because tv_sec size is different from what newlib expect
|
||||
* Newlib expects 64bits for seconds and PSP expects 32bits
|
||||
*/
|
||||
typedef struct SceKernelTimeval {
|
||||
uint32_t tv_sec;
|
||||
uint32_t tv_usec;
|
||||
} SceKernelTimeval;
|
||||
|
||||
/**
|
||||
* Get the time in seconds since the epoc (1st Jan 1970)
|
||||
*
|
||||
@@ -44,7 +53,7 @@ clock_t sceKernelLibcClock(void);
|
||||
/**
|
||||
* Get the current time of time and time zone information
|
||||
*/
|
||||
int sceKernelLibcGettimeofday(struct timeval *tp, struct timezone *tzp);
|
||||
int sceKernelLibcGettimeofday(struct SceKernelTimeval *tp, struct timezone *tzp);
|
||||
|
||||
/**
|
||||
* Write back the data cache to memory
|
||||
|
||||
Reference in New Issue
Block a user