qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3] linux-user: fix emulation of getdents


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH v3] linux-user: fix emulation of getdents
Date: Mon, 20 Aug 2012 23:05:40 +0100

On 20 August 2012 22:36, Dmitry V. Levin <address@hidden> wrote:
> In case when TARGET_ABI_BITS == 32 && HOST_LONG_BITS == 64, the last
> byte of the target dirent structure (aka d_type byte) was never copied
> from the host dirent structure, thus breaking everything that relies
> on valid d_type value, e.g. glob(3).

Looks pretty good, just one nit...

> diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
> index 2cfda5a..f7271fa 100644
> --- a/linux-user/syscall_defs.h
> +++ b/linux-user/syscall_defs.h
> @@ -258,7 +258,7 @@ struct target_dirent {
>         abi_long        d_ino;
>         abi_long        d_off;
>         unsigned short  d_reclen;
> -       char            d_name[256]; /* We must not include limits.h! */
> +       char            d_name[];
>  };

Can you convert this struct to match coding style while you're touching
it, please? (ie no hardcoded tabs). scripts/checkpatch.pl will let you
know about this kind of thing.

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]