summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorAlan Cox <alan@lxorguk.ukuu.org.uk>2009-03-23 10:37:57 +0000
committerChris Wright <chrisw@sous-sol.org>2009-04-02 13:55:18 -0700
commit86046cf121d09c4513f1c79c8726a761777988f0 (patch)
treec242f9858f5c010793267b77470ab170f80965c3 /drivers
parent4e3278e0e894eb08599dc3b2541f9f3a55ebeebf (diff)
ARM: cumana: Fix a long standing bogon
upstream commit: ecbf61e7357d5c7047c813edd6983902d158688c Should be using strncmp as the data from user space may be unterminated (Bug #8004) Signed-off-by: Alan Cox <alan@lxorguk.ukuu.org.uk Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/scsi/arm/cumana_2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/arm/cumana_2.c b/drivers/scsi/arm/cumana_2.c
index 68a64123af8f..ed502b7412d6 100644
--- a/drivers/scsi/arm/cumana_2.c
+++ b/drivers/scsi/arm/cumana_2.c
@@ -318,7 +318,7 @@ cumanascsi_2_set_proc_info(struct Scsi_Host *host, char *buffer, int length)
{
int ret = length;
- if (length >= 11 && strcmp(buffer, "CUMANASCSI2") == 0) {
+ if (length >= 11 && strncmp(buffer, "CUMANASCSI2", 11) == 0) {
buffer += 11;
length -= 11;