Github user sureshsubbiah commented on a diff in the pull request:
https://github.com/apache/incubator-trafodion/pull/914#discussion_r96464728
--- Diff: core/sql/exp/ExpHbaseInterface.cpp ---
@@ -271,7 +271,12 @@ Lng32 ExpHbaseInterface::coProcAggr(
char * getHbaseErrStr(Lng32 errEnum)
{
- return (char*)hbaseErrorEnumStr[errEnum - (Lng32)HBASE_MIN_ERROR_NUM];
+ Lng32 lv_errEnum;
+ if (errEnum < HBASE_MIN_ERROR_NUM || errEnum >= HBASE_MAX_ERROR_NUM)
+ lv_errEnum = HBASE_GENERIC_ERROR;
--- End diff --
It is good that we are adding this to catch unanticipated errors. Did
testing reveal any errors that are not on the list above. If yes, do you think
we can add to the list of errors in ExpHbaseDefs.h.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---