[Issue 1346] New: std.uri.decode/decodeComponent do not decode '+' plus

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Jul 18 08:35:25 PDT 2007


http://d.puremagic.com/issues/show_bug.cgi?id=1346

           Summary: std.uri.decode/decodeComponent do not decode '+' plus
           Product: D
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: alan at akbkhome.com


std.stdio.writefln("%s", std.uri.decode("cat+dog"));

expected output:
"cat dog"

actual output "cat+dog"

(you would normally get this by posting a web page with a space (eg. search for
something with a space on google)

Suggested Fix:
Line 269 of std/uri.d

     if (C == '+') { R[Rlen] = ' '; Rlen++; continue; }


-- 



More information about the Digitalmars-d-bugs mailing list