way to fix lex bug mentioned earlier

R. Curtis Jackson rcj at burl.UUCP
Tue Apr 24 09:11:18 AEST 1984


Several people have asked me questions like this:

>>> Any ideas on how to get lex to check YYLMAX rather than overwriting or
>>> increasing the buffer size.  I consider it a bug to allow overwriting
>>> in system software.

Well, I don't have the time right now to make them, but if you
feel like changing the function yylook() in /usr/lib/lex/ncform
it shouldn't be very difficult.  Just make sure that every assignment
into yytext and/or yysbuf has a check for YYLMAX chars already being
present in those character arrays.  I think that should do it.

Happy renovating [why call it nasty things like 'overhauling' or
'debugging' or 'patching'?],
-- 

The MAD Programmer -- 919-228-3313 (Cornet 291)
alias: Curtis Jackson	...![ ihnp4 ulysses cbosgd clyde ]!burl!rcj



More information about the Comp.unix.wizards mailing list