Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 143BE17B3D for ; Thu, 30 Oct 2014 23:16:35 +0000 (UTC) Received: (qmail 53950 invoked by uid 500); 30 Oct 2014 23:16:34 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 53879 invoked by uid 500); 30 Oct 2014 23:16:34 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 53749 invoked by uid 500); 30 Oct 2014 23:16:34 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 53725 invoked by uid 99); 30 Oct 2014 23:16:34 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Oct 2014 23:16:34 +0000 Date: Thu, 30 Oct 2014 23:16:34 +0000 (UTC) From: "Jason Dere (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HIVE-8579) Guaranteed NPE in DDLSemanticAnalyzer MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-8579?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jason Dere updated HIVE-8579: ----------------------------- Resolution: Fixed Status: Resolved (was: Patch Available) Committed to trunk/branch-0.14 > Guaranteed NPE in DDLSemanticAnalyzer > ------------------------------------- > > Key: HIVE-8579 > URL: https://issues.apache.org/jira/browse/HIVE-8579 > Project: Hive > Issue Type: Bug > Reporter: Lars Francke > Assignee: Jason Dere > Fix For: 0.14.0 > > Attachments: HIVE-8579.1.patch, HIVE-8579.1.patch > > > This was added by [~jdere] in HIVE-8411. I don't fully understand the code (i.e. what it means when desc is null) but I'm sure, Jason, you can fix it without much trouble? > {code} > if (desc == null || !AlterTableDesc.doesAlterTableTypeSupportPartialPartitionSpec(desc.getOp())) { > throw new SemanticException( ErrorMsg.ALTER_TABLE_TYPE_PARTIAL_PARTITION_SPEC_NO_SUPPORTED, desc.getOp().name()); > } else if (!conf.getBoolVar(HiveConf.ConfVars.DYNAMICPARTITIONING)) { > throw new SemanticException(ErrorMsg.DYNAMIC_PARTITION_DISABLED); > } > {code} > You check for whether {{desc}} is null but then use it to do {{desc.getOp()}}. -- This message was sent by Atlassian JIRA (v6.3.4#6332)