Trivial fix to phram.c
Subsystems (2)
PATCH 1/1 Trivial fix to phram.c
I'm not sure if gmail likes to mangle stuff a lot, so I'll include this patch both inline and as an attachment.
--- linux-2.6.7/drivers/mtd/devices/phram.c 2004-08-04
22:29:04.850552576 +0300
+++ linux-2.6.7/drivers/mtd/devices/phram.c.argument_fix
2004-08-04 22:25:04.557082736 +0300
@@ -231,14 +231,15 @@
static int phram_setup(const char *val, struct kernel_param *kp) {
- char buf[64+12+12], *str = buf;
+ const int buflen = 88;
+ char buf[buflen], *str = buf;
char *token[3];
char *name;
uint32_t start;
uint32_t len;
int i, ret;- if (strnlen(val, sizeof(str)) >= sizeof(str))
+ if (strnlen(val, buflen) >= buflen)
parse_err("parameter too long\n");
strcpy(str, val);drivers/mtd/devices/phram.c.argument_fix renamed from drivers/mtd/devices/phram.c +3 -2
@@ -231,14 +231,15 @@ static int phram_setup(const char *val, struct kernel_param *kp) { - char buf[64+12+12], *str = buf; + const int buflen = 88; + char buf[buflen], *str = buf; char *token[3]; char *name; uint32_t start; uint32_t len; int i, ret; - if (strnlen(val, sizeof(str)) >= sizeof(str)) + if (strnlen(val, buflen) >= buflen) parse_err("parameter too long\n"); strcpy(str, val);
Quoted 3 lines · Ari Rahikkala
I'm not sure if gmail likes to mangle stuff a lot, so I'll include this patch both inline and as an attachment.
Patch is fine. David, does cvs via ipv4 work again?
Quoted 12 lines
---
linux-2.6.7/drivers/mtd/devices/phram.c2004-08-04
22:29:04.850552576 +0300
+++ linux-2.6.7/drivers/mtd/devices/phram.c.argument_fix2004-08-04 22:25:04.557082736 +0300drivers/mtd/devices/phram.c.argument_fix renamed from drivers/mtd/devices/phram.c +2
-1@@ -231,14 +231,15 @@ static int phram_setup(const char *val, struct kernel_param *kp) { - char buf[64+12+12], *str = buf; + const int buflen = 88; + char buf[buflen], *str = buf; char *token[3];
drivers/mtd/devices/phram.c.argument_fix line 245
Quoted 10 lines
drivers/mtd/devices/phram.c.argument_fix renamed from drivers/mtd/devices/phram.c +1
-1char *name; uint32_t start; uint32_t len; int i, ret; - if (strnlen(val, sizeof(str)) >= sizeof(str)) + if (strnlen(val, buflen) >= buflen) parse_err("parameter too long\n"); strcpy(str, val);
Jörn
Signature · 4 lines
My second remark is that our intellectual powers are rather geared to master static relations and that our powers to visualize processes evolving in time are relatively poorly developed. -- Edsger W. Dijkstra
Quoted 6 lines · Jörn Engel
Quoted 3 lines · Ari Rahikkala
I'm not sure if gmail likes to mangle stuff a lot, so I'll include this patch both inline and as an attachment.
Patch is fine. David, does cvs via ipv4 work again?
Not yet. Does anyone still not have IPv6? :)
Signature · 1 line
dwmw2
Quoted 2 lines · David Woodhouse
Not yet. Does anyone still not have IPv6? :)
Does it involve work to set things up? ;)
Jörn
Signature · 3 lines
The wise man seeks everything in himself; the ignorant man tries to get everything from somebody else. -- unknown
Quoted 5 lines · Jörn Engel
Quoted 2 lines · David Woodhouse
Not yet. Does anyone still not have IPv6? :)
Does it involve work to set things up? ;)
Yeah. Four lines added to your network config scripts.
http://www.linux-mtd.infradead.org/
Signature · 1 line
dwmw2
Quoted 6 lines · David Woodhouse
Quoted 2 lines · Jörn Engel
Does it involve work to set things up? ;)
Yeah. Four lines added to your network config scripts.
http://www.linux-mtd.infradead.org/
o Debian
o Company firewall
o No internet at home (I'm a cheap and lazy bastard)
Fsck!
Jörn
Signature · 2 lines
The only real mistake is the one from which we learn nothing. -- John Powell
Quoted 11 lines · Jörn Engel
Quoted 6 lines · David Woodhouse
Quoted 2 lines · Jörn Engel
Does it involve work to set things up? ;)
Yeah. Four lines added to your network config scripts.
http://www.linux-mtd.infradead.org/o Debian
o Company firewall
o No internet at home (I'm a cheap and lazy bastard)
SSH's ProxyCommand option is a wonderful thing.
Host cvs.infradead.org
ProxyCommand ssh <someipv6capablebox> exec netcat %h %p
Signature · 1 line
dwmw2