[ECOS] [PATCH] enlarge allowable size of diagnostic strings
Thu Jan 17 13:13:00 GMT 2002
jeroen dobbelaere wrote:
> Andrew Lunn wrote:
> > Wouldn't it be better to put the if outside the loop? At the moment
> > its evaluated for every character. This will catch a string that is not
> > terminated within 256 characters. If you put it outside the loop there
> > is a small danger that a string does not have a termination before the
> > end of memory. In that case you will get an exception when you fall of
> > the edge of the world rather than a "Not a string" message. But you
> > get a speedup in the normal case.
> > Andrew
> I guess the 'diag_check_string' function exists to prevent a possible
> 'falling of the edge'...
I agree with Jeroen. The principle is to anticipate problems and prevent
them in advance.
> (although I would rather like to see this edge at 2048 bytes, than at 256)
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine
More information about the Ecos-discuss