Skip to content

Commit

Permalink
reset the bytebuffer after we capture the string
Browse files Browse the repository at this point in the history
CR feedback considered harmful.
  • Loading branch information
Ben Osheroff committed Oct 29, 2015
1 parent c337bb5 commit 55ea247
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -339,9 +339,9 @@ public List<String> toJSONStrings() {
for ( RowMap map : jsonMaps() ) {
try {
rowMapToJSON(g, map);
b.reset();
g.flush();
list.add(b.toString());
b.reset();
} catch ( IOException e ) {
LOGGER.error("Caught IOException while generating JSON: " + e, e);
}
Expand Down

2 comments on commit 55ea247

@osheroff
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vanchi-zendesk could I get a retroactive plusone on this commit?

@vanchi-zendesk
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Please sign in to comment.