git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Petr Baudis <pasky@ucw.cz>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Brad Roberts <braddr@puremagic.com>, git@vger.kernel.org
Subject: Re: [patch] fork optional branch point normazilation
Date: Mon, 18 Apr 2005 02:23:26 +0200	[thread overview]
Message-ID: <20050418002326.GC1461@pasky.ji.cz> (raw)
In-Reply-To: <Pine.LNX.4.58.0504171636590.7211@ppc970.osdl.org>

Dear diary, on Mon, Apr 18, 2005 at 01:39:10AM CEST, I got a letter
where Linus Torvalds <torvalds@osdl.org> told me that...
> 
> 
> On Sun, 17 Apr 2005, Brad Roberts wrote:
> >
> > braddr:x:1000:1000:Brad Roberts,,,:/home/braddr:/bin/bash
> > 
> > All gecos entries on all my debian boxes are of the form:
> > 
> >    fullname, office number, office extension, and home number
> 
> Ahh, ok.
> 
> I'll make the "cleanup" thing just remove strange characters from the end, 
> that should fix this kind of thing for now.
> 
> I'd just remove everything after the first strange number, but I can also 
> see people using the "lastname, firstname" format, and I'd hate to just 
> ignore firstname in that case.

> +       /*
> +        * Go back, and remove crud from the end: some people
> +        * have commas etc in their gecos field
> +        */
> +       dst--;
> +       while (--dst >= p) {
> +               unsigned char c = *dst;
> +               switch (c) {
> +               case ',': case ';': case '.':
> +                       *dst = 0;
> +                       continue;
> +               }
> +               break;
> +       }

Am I just slow or does the first dst-- make it miss the last trailing
/[,;.]/?

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor

  reply	other threads:[~2005-04-18  0:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-17 12:04 [patch] fork optional branch point normazilation Brad Roberts
2005-04-17 12:25 ` Petr Baudis
2005-04-17 12:40   ` Brad Roberts
2005-04-17 17:13 ` [patch] " Linus Torvalds
2005-04-17 17:21   ` Daniel Barkalow
2005-04-17 23:27   ` Brad Roberts
2005-04-17 23:39     ` Linus Torvalds
2005-04-18  0:23       ` Petr Baudis [this message]
2005-04-18  1:07         ` Linus Torvalds
2005-04-18  1:51           ` [PATCH] remove_special() tentative fix Junio C Hamano
2005-04-18  2:01           ` [patch] fork optional branch point normazilation Brad Roberts
2005-04-18 10:45       ` Martin Schlemmer

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=20050418002326.GC1461@pasky.ji.cz \
    --to=pasky@ucw.cz \
    --cc=braddr@puremagic.com \
    --cc=git@vger.kernel.org \
    --cc=torvalds@osdl.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).