From: Domen Puncer <domen@coderock.org>
To: kernel-janitors@vger.kernel.org
Subject: Re: [KJ] [PATCH 2.6.12] [RESEND] /proc/tty/driver/* filtering for non
Date: Thu, 30 Jun 2005 13:48:45 +0000 [thread overview]
Message-ID: <20050630134845.GA16115@nd47.coderock.org> (raw)
In-Reply-To: <20050622194756.GA6699@dansme-mobile.smertnig>
[-- Attachment #1: Type: text/plain, Size: 1402 bytes --]
On 30/06/05 15:01 +0200, Daniel Smertnig wrote:
> On 6/29/05, Domen Puncer <domen@coderock.org> wrote:
> > On 22/06/05 21:47 +0200, Daniel Smertnig wrote:
> > > diff --git a/drivers/char/amiserial.c b/drivers/char/amiserial.c
> > > --- a/drivers/char/amiserial.c
> > > +++ b/drivers/char/amiserial.c
> > > @@ -1876,6 +1876,17 @@ static inline int line_info(char *buf, s
> > > info->quot = 0;
> > > info->tty = NULL;
> > > }
> > > +
> > > + if (info->quot) {
> > > + ret += sprintf(buf+ret, " baud:%d",
> > > + state->baud_base / info->quot);
> > > + }
> > > +
> > > + if (!capable(CAP_SYS_RAWIO)) {
> > > + strcat(buf, "\n");
> > > + return ret + 1;
> >
> > So... we overwrite first two bytes, and then return the whole string?
> > Or am I missing something?
>
> I don't see any problem here? A newline is appended to the string and
> the total length of the string (previous length "ret" + 1 for the
> newline) is returned.
Ahh... I think I get your intent.
That should be strcat(buf+ret, "\n"); , right?
>
> > > + }
> > > +
> >
> > ^^ you introduce whitespace.
>
> Sorry, i will resend with that fixed
>
> _______________________________________________
> Kernel-janitors mailing list
> Kernel-janitors@lists.osdl.org
> http://lists.osdl.org/mailman/listinfo/kernel-janitors
[-- Attachment #2: Type: text/plain, Size: 167 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
http://lists.osdl.org/mailman/listinfo/kernel-janitors
next prev parent reply other threads:[~2005-06-30 13:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-22 19:47 [KJ] [PATCH 2.6.12] [RESEND] /proc/tty/driver/* filtering for non Daniel Smertnig
2005-06-29 10:42 ` Domen Puncer
2005-06-29 11:01 ` [KJ] [PATCH 2.6.12] [RESEND] /proc/tty/driver/* filtering for walter harms
2005-06-30 13:01 ` [KJ] [PATCH 2.6.12] [RESEND] /proc/tty/driver/* filtering for non Daniel Smertnig
2005-06-30 13:05 ` Daniel Smertnig
2005-06-30 13:48 ` Domen Puncer [this message]
2005-06-30 13:56 ` Daniel Smertnig
2005-06-30 15:50 ` Domen Puncer
2005-06-30 17:23 ` Daniel Smertnig
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=20050630134845.GA16115@nd47.coderock.org \
--to=domen@coderock.org \
--cc=kernel-janitors@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).