public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: "Jörn Engel" <joern@wohnheim.fh-wedel.de>
To: Ari Rahikkala <ari.rahikkala@gmail.com>
Cc: linux-mtd@lists.infradead.org
Subject: Re: [PATCH] Trivial fix to phram.c
Date: Thu, 5 Aug 2004 14:52:50 +0200	[thread overview]
Message-ID: <20040805125250.GA29762@wohnheim.fh-wedel.de> (raw)
In-Reply-To: <e2041ca104080412415a9ce4e8@mail.gmail.com>

On Wed, 4 August 2004 22:41:32 +0300, Ari Rahikkala wrote:
> 
> 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?

> --- 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);


Jörn

-- 
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

  reply	other threads:[~2004-08-05 12:54 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-04 19:41 [PATCH] Trivial fix to phram.c Ari Rahikkala
2004-08-05 12:52 ` Jörn Engel [this message]
2004-08-05 13:05   ` David Woodhouse
2004-08-05 14:14     ` Jörn Engel
2004-08-05 14:25       ` David Woodhouse
2004-08-05 14:30         ` Jörn Engel
2004-08-05 14:41           ` David Woodhouse

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040805125250.GA29762@wohnheim.fh-wedel.de \
    --to=joern@wohnheim.fh-wedel.de \
    --cc=ari.rahikkala@gmail.com \
    --cc=linux-mtd@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox