Re: [PATCH] nfsd: fix pointer dereference in dprintk of write verifiers

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

 



Bruce, this is for the pnfsd branch so please ignore for upstream

Benny

On Jun. 29, 2010, 15:49 +0300, Benny Halevy <bhalevy@xxxxxxxxxxx> wrote:
> Signed-off-by: Benny Halevy <bhalevy@xxxxxxxxxxx>
> ---
>  fs/nfsd/nfs4xdr.c |    8 ++++----
>  1 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c
> index 225023c..8b41a9d 100644
> --- a/fs/nfsd/nfs4xdr.c
> +++ b/fs/nfsd/nfs4xdr.c
> @@ -2552,8 +2552,8 @@ nfsd4_encode_commit(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_
>  		RESERVE_SPACE(8);
>  		WRITEMEM(commit->co_verf.data, 8);
>  		dprintk("NFSD: nfsd4_encode_commit: verifier %x:%x\n",
> -			*(u32 *)(&commit->co_verf.data)[0],
> -			*(u32 *)(&commit->co_verf.data)[1]);
> +			((u32 *)(&commit->co_verf.data))[0],
> +			((u32 *)(&commit->co_verf.data))[1]);
>  
>  		ADJUST_ARGS();
>  	}
> @@ -3127,8 +3127,8 @@ nfsd4_encode_write(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_w
>  		WRITE32(write->wr_how_written);
>  		WRITEMEM(write->wr_verifier.data, 8);
>  		dprintk("NFSD: nfsd4_encode_write: verifier %x:%x\n",
> -			*(u32 *)(&write->wr_verifier.data)[0],
> -			*(u32 *)(&write->wr_verifier.data)[1]);
> +			((u32 *)(&write->wr_verifier.data))[0],
> +			((u32 *)(&write->wr_verifier.data))[1]);
>  		ADJUST_ARGS();
>  	}
>  	return nfserr;
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux