Well, it's incrementing an unmanaged pointer one `wchar` at time, but I don't think there's much to worry about.  I think the only 2 options here are

* Scan the string until you hit NULL
* Grab too much memory and trim off the fat

IMHO, the first option is better.