V4L/DVB (13287): ce6230 - saa7164-cmd: Fix wrong sizeof

Which is why I have always preferred sizeof(struct foo) over
sizeof(var).

Cc: Antti Palosaari <crope@iki.fi>
Acked-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
Jean Delvare 2009-11-04 15:26:59 -03:00 committed by Mauro Carvalho Chehab
parent d514edac5d
commit 7157fbd0ed
2 changed files with 2 additions and 2 deletions

View File

@ -105,7 +105,7 @@ static int ce6230_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[],
int i = 0; int i = 0;
struct req_t req; struct req_t req;
int ret = 0; int ret = 0;
memset(&req, 0, sizeof(&req)); memset(&req, 0, sizeof(req));
if (num > 2) if (num > 2)
return -EINVAL; return -EINVAL;

View File

@ -347,7 +347,7 @@ int saa7164_cmd_send(struct saa7164_dev *dev, u8 id, tmComResCmd_t command,
/* Prepare some basic command/response structures */ /* Prepare some basic command/response structures */
memset(&command_t, 0, sizeof(command_t)); memset(&command_t, 0, sizeof(command_t));
memset(&response_t, 0, sizeof(&response_t)); memset(&response_t, 0, sizeof(response_t));
pcommand_t = &command_t; pcommand_t = &command_t;
presponse_t = &response_t; presponse_t = &response_t;
command_t.id = id; command_t.id = id;