Skip to content

Commit

Permalink
Add missing quotes around body in JSON
Browse files Browse the repository at this point in the history
Gson was parsing this malformed JSON, but it wasn't actually correct
without this escaping.

Before the message would look like:

```json
{"seq":10,"type":"response","request_seq":4,"command":"foo","success":true,body:{"allThreadsContinued":false}}
```

Now it looks like:

```json
{"seq":10,"type":"response","request_seq":4,"command":"foo","success":true,"body":{"allThreadsContinued":false}}

```
  • Loading branch information
jonahgraham committed May 2, 2023
1 parent a526054 commit 7040d87
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -860,7 +860,7 @@ private Object voidResponse(String body) {

String bodyField = "";
if (body != null) {
bodyField = ",body:" + body;
bodyField = ",\"body\":" + body;
}

Message message = handler.parseMessage("{\"seq\":10," //
Expand Down

0 comments on commit 7040d87

Please sign in to comment.