cvs commit: src/lib/libc/regex engine.c

Tim J. Robbins tjr at FreeBSD.org
Sat Nov 20 19:14:33 PST 2004


tjr         2004-11-21 03:14:32 UTC

  FreeBSD src repository

  Modified files:
    lib/libc/regex       engine.c 
  Log:
  Fix computation of the 'n' argument to mbrtowc (through XMBRTOWC) to avoid
  reading past 'stop' in various places when converting multibyte characters.
  Reading too far caused truncation to not be detected when it should have
  been, eventually causing regexec() to loop infinitely in with certain
  combinations of patterns and strings in multibyte locales.
  
  PR:             74020
  MFC after:      4 weeks
  
  Revision  Changes    Path
  1.15      +4 -4      src/lib/libc/regex/engine.c


More information about the cvs-src mailing list