summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/gspca/mars.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-07-19 17:45:17 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-07-19 17:45:17 -0300
commit2ed77cf169e469102ebe5fd8d03e6b083323f26e (patch)
tree0d7946fcc1952725dbb024d0f12494d8ff8c30c1 /linux/drivers/media/video/gspca/mars.c
parent6546c948a53d82262632181128918dd96f5527b0 (diff)
parent13f81b30dcdaede4d7b3fc982a6d63c494aff666 (diff)
downloadmediapointer-dvb-s2-2ed77cf169e469102ebe5fd8d03e6b083323f26e.tar.gz
mediapointer-dvb-s2-2ed77cf169e469102ebe5fd8d03e6b083323f26e.tar.bz2
merge: http://linuxtv.org/hg/~jfrancois/v4l-dvb
From: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video/gspca/mars.c')
-rw-r--r--linux/drivers/media/video/gspca/mars.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/linux/drivers/media/video/gspca/mars.c b/linux/drivers/media/video/gspca/mars.c
index 789fd178a..68dd1ea0f 100644
--- a/linux/drivers/media/video/gspca/mars.c
+++ b/linux/drivers/media/video/gspca/mars.c
@@ -201,6 +201,8 @@ static int sd_start(struct gspca_dev *gspca_dev)
/* create the JPEG header */
sd->jpeg_hdr = kmalloc(JPEG_HDR_SZ, GFP_KERNEL);
+ if (!sd->jpeg_hdr)
+ return -ENOMEM;
jpeg_define(sd->jpeg_hdr, gspca_dev->height, gspca_dev->width,
0x21); /* JPEG 422 */
jpeg_set_qual(sd->jpeg_hdr, sd->quality);