zrlw commented on code in PR #95:
URL: https://github.com/apache/dubbo-hessian-lite/pull/95#discussion_r2365105244


##########
hessian-lite/src/main/java/com/alibaba/com/caucho/hessian/io/MapDeserializer.java:
##########
@@ -163,13 +163,11 @@ public Object readObject(AbstractHessianInput in,
         return map;
     }
 
-    private Map createMap()
+    private Map createMap(int expectedSize)
             throws IOException {
 
-        if (_type == null)
-            return new HashMap();
-        else if (_type.equals(Map.class))
-            return new HashMap();
+        if (_type == null || _type.equals(Map.class) || 
_type.equals(HashMap.class))

Review Comment:
   i see, it could be tested through generic testing if the server returns a 
object which class that client does not have.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@dubbo.apache.org
For additional commands, e-mail: notifications-h...@dubbo.apache.org

Reply via email to