Skip to content

Commit

Permalink
V4L/DVB (6467): v4l2-common: minor cleanups
Browse files Browse the repository at this point in the history
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed Jan 25, 2008
1 parent a2e521e commit 393bf55
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/media/video/v4l2-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -1028,13 +1028,12 @@ int v4l2_i2c_attach(struct i2c_adapter *adapter, int address, struct i2c_driver
client->addr = address;
client->adapter = adapter;
client->driver = driver;
snprintf(client->name, sizeof(client->name) - 1, name);
strlcpy(client->name, name, sizeof(client->name));

err = probe(client);
if (err == 0) {
i2c_attach_client(client);
}
else {
} else {
kfree(client);
}
return err != -ENOMEM ? 0 : err;
Expand Down

0 comments on commit 393bf55

Please sign in to comment.