You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@hive.apache.org by GitBox <gi...@apache.org> on 2020/07/07 07:17:28 UTC

[GitHub] [hive] kgyrtkirk commented on a change in pull request #1209: HIVE-22412: StatsUtils throw NPE when explain

kgyrtkirk commented on a change in pull request #1209:
URL: https://github.com/apache/hive/pull/1209#discussion_r450655717



##########
File path: serde/src/java/org/apache/hadoop/hive/serde2/objectinspector/StandardConstantMapObjectInspector.java
##########
@@ -40,8 +41,10 @@ protected StandardConstantMapObjectInspector() {
    */
    protected StandardConstantMapObjectInspector(ObjectInspector mapKeyObjectInspector,
        ObjectInspector mapValueObjectInspector, Map<?, ?> value) {
-    super(mapKeyObjectInspector, mapValueObjectInspector);
-    this.value = value;
+     super(mapKeyObjectInspector, mapValueObjectInspector);
+     if (null != value) {

Review comment:
       please remove this and similar conditionals.... a map which is `NULL` is not `EMPTY`!
   this should be fixed in `StatsUtils`
   




----------------------------------------------------------------
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.

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



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org