[Freeciv-Dev] Re: new natural names patch (PR#1127)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
--- Jason Short <vze2zq63@xxxxxxxxxxx> wrote: > Chris Richards wrote:
>
> > Since the operation is destructive already, why not memmove the
> > contents to the beginning of the input address? As it stands, the
> > return param has to save off an additional pointer or strdup the
> value
> > anyway--no re-using the input param. So it is more like,
> > trim-and-copy than just trim.
> >
> > Secondly, passing in a string that is str[0] = '\0' will blow-up your
> > reverse processing--you'll underrun your buffer with the str--;.
>
> Good points.
But you want to memmove only if s1>s2 (i.e. there was some initial
whitespace)
G.
__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com
- [Freeciv-Dev] Re: new natural names patch (PR#1127), (continued)
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Petr Baudis, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Erik Sigra, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Petr Baudis, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Erik Sigra, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Jason Short, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Erik Sigra, 2001/12/24
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Petr Baudis, 2001/12/24
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Jason Short, 2001/12/22
- [Freeciv-Dev] Re: new natural names patch (PR#1127), mateusz stefek, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127), Erik Sigra, 2001/12/23
- [Freeciv-Dev] Re: new natural names patch (PR#1127),
Gregory Berkolaiko <=
|
|