[PATCH 039/577] staging: frontier: switch to strict_strtoul in tranzport.c
Greg Kroah-Hartman
gregkh at suse.de
Fri May 21 19:56:08 UTC 2010
From: Eli Lindsey <eli at siliconsprawl.com>
This is a patch to tranzport.c that changes a use of simple_strtoul to
strict_strtoul at the suggestion of checkpatch.pl
Signed-off-by: Eli Lindsey <eli at siliconsprawl.com>
Signed-off-by: Greg Kroah-Hartman <gregkh at suse.de>
---
drivers/staging/frontier/tranzport.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/staging/frontier/tranzport.c b/drivers/staging/frontier/tranzport.c
index 1f91001..f9ab4f3 100644
--- a/drivers/staging/frontier/tranzport.c
+++ b/drivers/staging/frontier/tranzport.c
@@ -198,7 +198,9 @@ static void usb_tranzport_abort_transfers(struct usb_tranzport *dev)
{ \
struct usb_interface *intf = to_usb_interface(dev); \
struct usb_tranzport *t = usb_get_intfdata(intf); \
- int temp = simple_strtoul(buf, NULL, 10); \
+ unsigned long temp; \
+ if (strict_strtoul(buf, 10, &temp)) \
+ return -EINVAL; \
t->value = temp; \
return count; \
} \
--
1.7.0.3
More information about the devel
mailing list