July 18, 2007 [Issue 1347] New: invalid UTF-8 strings cause access violations and inconsistent behavior in std.regexp | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=1347 Summary: invalid UTF-8 strings cause access violations and inconsistent behavior in std.regexp Product: D Version: 1.018 Platform: PC OS/Version: Windows Status: NEW Severity: minor Priority: P3 Component: Phobos AssignedTo: bugzilla@digitalmars.com ReportedBy: thecybershadow@gmail.com import std.regexp; void main() { ubyte[] data = [0xFF]; RegExp re = new RegExp(`.*`); re.test(cast(char[])data); } --- Caused me some headache when I to process some non-Unicode files and forgot to convert the data. -- |
September 03, 2007 [Issue 1347] invalid UTF-8 strings cause access violations and inconsistent behavior in std.regexp | ||||
---|---|---|---|---|
| ||||
Posted in reply to d-bugmail | http://d.puremagic.com/issues/show_bug.cgi?id=1347 bugzilla@digitalmars.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WONTFIX ------- Comment #1 from bugzilla@digitalmars.com 2007-09-03 15:07 ------- std.regexp is designed to work only with valid UTF strings. To validate UTF strings, which should be done for input coming from an untrusted source, use the function std.utf.validate(). -- |
Copyright © 1999-2021 by the D Language Foundation