diff options
author | pbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162> | 2007-06-07 23:09:47 +0000 |
---|---|---|
committer | pbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162> | 2007-06-07 23:09:47 +0000 |
commit | 29b3a6627e57585a156fb753c7781b4b1646a934 (patch) | |
tree | cb1c78bb8fdc8816d3c384a7c625653435f24946 /m68k-semi.c | |
parent | 0fa7f157309dedfd715179241a70b43739a45fb1 (diff) | |
download | qemu-29b3a6627e57585a156fb753c7781b4b1646a934.zip |
Windows build fixes.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2959 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'm68k-semi.c')
-rw-r--r-- | m68k-semi.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/m68k-semi.c b/m68k-semi.c index 27bdce8e2f..73224f181a 100644 --- a/m68k-semi.c +++ b/m68k-semi.c @@ -116,8 +116,14 @@ static void translate_stat(CPUState *env, target_ulong addr, struct stat *s) p->gdb_st_gid = cpu_to_be32(s->st_gid); p->gdb_st_rdev = cpu_to_be32(s->st_rdev); p->gdb_st_size = cpu_to_be64(s->st_size); +#ifdef _WIN32 + /* Windows stat is missing some fields. */ + p->gdb_st_blksize = 0; + p->gdb_st_blocks = 0; +#else p->gdb_st_blksize = cpu_to_be64(s->st_blksize); p->gdb_st_blocks = cpu_to_be64(s->st_blocks); +#endif p->gdb_st_atime = cpu_to_be32(s->st_atime); p->gdb_st_mtime = cpu_to_be32(s->st_mtime); p->gdb_st_ctime = cpu_to_be32(s->st_ctime); @@ -281,9 +287,9 @@ void do_m68k_semihosting(CPUM68KState *env, int nr) ARG(0), ARG(1)); return; } else { - struct timeval tv; + qemu_timeval tv; struct gdb_timeval *p; - result = gettimeofday(&tv, NULL); + result = qemu_gettimeofday(&tv); if (result != 0) { p = lock_user(ARG(0), sizeof(struct gdb_timeval), 0); p->tv_sec = cpu_to_be32(tv.tv_sec); |