What steps will reproduce the problem?
string s = new string('.', 4086);
var opts =
Google.ProtocolBuffers.DescriptorProtos.FileDescriptorProto.CreateBuilder()
.SetName(s)
.SetPackage("package")
.BuildPartial();
string t = opts.ToJson();
What is the expected output? What do you see instead?
Expect json string, instead see IndexOutOfRangeException thrown.
What version of the product are you using? On what operating system?
* 2.4.1.521 from nuget.
Please provide any additional information below.
* JsonTextWriter needs to check _output for null before calling Flush() when
writing a single character like it does when writing an array.
* Work-around is to not use built-in ToJson() extension, but instead use one
that supplies a MemoryStream.
JsonFormatWriter w = JsonFormatWriter.CreateInstance(new MemoryStream());
Original issue reported on code.google.com by jacobgla...@yahoo.com on 12 Aug 2013 at 5:04
Original issue reported on code.google.com by
jacobgla...@yahoo.com
on 12 Aug 2013 at 5:04