Open paidir opened 8 years ago
The first step is: don't ignore the error that snappyReader.Read is returning.
After that, I'm only guessing, but there is a difference between the block Snappy format, and the streaming Snappy format. The streaming format is the block format plus a framing header. The snappy.Reader is for the streaming format, but most people use the block format. Try this instead:
decoded, err := snappy.Decode(nil, []byte(pbMsg.GetBody().GetReqData().GetContent()))
code:
line:pbMsg.GetBody().GetReqData().GetContent() return a string . when using the stringReader as the paramater , the rNum is 0, why? 3q very much