This is an automated email from the ASF dual-hosted git repository.
liujun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git
The following commit(s) were added to refs/heads/master by this push:
new d5c5176 port #3568 into main trunk (#3993)
d5c5176 is described below
commit d5c517607b5bb5360c56b8d619799b2795594040
Author: Ian Luo <[email protected]>
AuthorDate: Fri May 10 13:01:06 2019 +0800
port #3568 into main trunk (#3993)
fixes #3991
---
.../src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboCodec.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git
a/dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboCodec.java
b/dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboCodec.java
index 38650c2..bc8c747 100644
---
a/dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboCodec.java
+++
b/dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboCodec.java
@@ -73,12 +73,13 @@ public class DubboCodec extends ExchangeCodec {
byte status = header[3];
res.setStatus(status);
try {
- ObjectInput in = CodecSupport.deserialize(channel.getUrl(),
is, proto);
if (status == Response.OK) {
Object data;
if (res.isHeartbeat()) {
+ ObjectInput in =
CodecSupport.deserialize(channel.getUrl(), is, proto);
data = decodeHeartbeatData(channel, in);
} else if (res.isEvent()) {
+ ObjectInput in =
CodecSupport.deserialize(channel.getUrl(), is, proto);
data = decodeEventData(channel, in);
} else {
DecodeableRpcResult result;
@@ -97,6 +98,7 @@ public class DubboCodec extends ExchangeCodec {
}
res.setResult(data);
} else {
+ ObjectInput in =
CodecSupport.deserialize(channel.getUrl(), is, proto);
res.setErrorMessage(in.readUTF());
}
} catch (Throwable t) {