fix some string marshaling bugs in the Dot Net binding -- Chris Larsen