From patchwork Thu Jul 23 21:17:11 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roel Kluin X-Patchwork-Id: 37026 X-Patchwork-Delegate: dougsland@redhat.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n6NLErWp006849 for ; Thu, 23 Jul 2009 21:14:53 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752178AbZGWVOs (ORCPT ); Thu, 23 Jul 2009 17:14:48 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753105AbZGWVOs (ORCPT ); Thu, 23 Jul 2009 17:14:48 -0400 Received: from mail-ew0-f226.google.com ([209.85.219.226]:34826 "EHLO mail-ew0-f226.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752178AbZGWVOr (ORCPT ); Thu, 23 Jul 2009 17:14:47 -0400 Received: by ewy26 with SMTP id 26so1335422ewy.37 for ; Thu, 23 Jul 2009 14:14:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:subject:content-type :content-transfer-encoding; bh=pbckwJeq06eGmQUa/Atv4eNxeP2kcZsNn7p0fHM0a48=; b=EEFi0OWJ7i5mRTzHfK7+LpN7YnJhZpz2p76tSkfe6GMPVOJRhBVNzscO0hG5RudwSa n88Ela8cZuHd0PEa75Z7rfRVQ93cuU/ytHfZrdlpkALToJV7sehTTzFZppnbKihyi8fe K994nGhEec9i2Kv3wRJHa2okfmuIeKA5fsE/Y= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding; b=N+jsXDs9h0lFNrGGtOMJrOjG+9qGoixdt+6P8aPy481EludvEQtbCP1ni24WJtXJHu YMbHV8WfnYFyeTolcxmzuvSY7T5UnZa98mccYLKfR1R7ggW3Zo7am4Y+RU5Lqnk2qknT qe+C9p0TAYydpNxKibdUX1FImKIn++UJ0T2lQ= Received: by 10.210.29.9 with SMTP id c9mr8779361ebc.45.1248383686433; Thu, 23 Jul 2009 14:14:46 -0700 (PDT) Received: from zoinx.mars (d133062.upc-d.chello.nl [213.46.133.62]) by mx.google.com with ESMTPS id 7sm371825eyg.36.2009.07.23.14.14.45 (version=SSLv3 cipher=RC4-MD5); Thu, 23 Jul 2009 14:14:45 -0700 (PDT) Message-ID: <4A68D357.3010502@gmail.com> Date: Thu, 23 Jul 2009 23:17:11 +0200 From: Roel Kluin User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1b3pre) Gecko/20090513 Fedora/3.0-2.3.beta2.fc11 Thunderbird/3.0b2 MIME-Version: 1.0 To: mchehab@redhat.com, linux-media@vger.kernel.org, Andrew Morton Subject: [PATCH] Read buffer overflow Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org parport[n] is checked before n < MAX_CAMS Signed-off-by: Roel Kluin --- probably harmless -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/media/video/bw-qcam.c b/drivers/media/video/bw-qcam.c index 10dbd4a..9e39bc5 100644 --- a/drivers/media/video/bw-qcam.c +++ b/drivers/media/video/bw-qcam.c @@ -992,7 +992,7 @@ static int accept_bwqcam(struct parport *port) if (parport[0] && strncmp(parport[0], "auto", 4) != 0) { /* user gave parport parameters */ - for(n=0; parport[n] && n