ACK: [PATCH] bios: mtrr: move buffer memset() to after failed is declared.
Alex Hung
alex.hung at canonical.com
Thu Dec 13 02:10:39 UTC 2012
On 12/07/2012 08:12 AM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> the memset() on the buffer should be after all the variables are
> declared to make it conform to the fwts house style.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
> src/bios/mtrr/mtrr.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/bios/mtrr/mtrr.c b/src/bios/mtrr/mtrr.c
> index 294e80b..e2ee506 100644
> --- a/src/bios/mtrr/mtrr.c
> +++ b/src/bios/mtrr/mtrr.c
> @@ -249,9 +249,10 @@ static int validate_iomem(fwts_framework *fw)
> FILE *file;
> char buffer[4096];
> int pcidepth = 0;
> - memset(buffer, 0, 4096);
> int failed = 0;
>
> + memset(buffer, 0, 4096);
> +
> if ((file = fopen("/proc/iomem", "r")) == NULL)
> return FWTS_ERROR;
>
>
Acked-by: Alex Hung <alex.hung at canonical.com>
More information about the fwts-devel
mailing list