You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafodion.apache.org by hz...@apache.org on 2017/07/04 02:47:53 UTC

[1/2] incubator-trafodion git commit: [TRAFODION-2675] Fix for seabase/TEST010 failure

Repository: incubator-trafodion
Updated Branches:
  refs/heads/master e1edb7de5 -> 72bf9b738


[TRAFODION-2675] Fix for seabase/TEST010 failure

When extracting text, don't include any NUL (0) bytes in the result.


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/27b7671a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/27b7671a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/27b7671a

Branch: refs/heads/master
Commit: 27b7671aed4c3be711176cb547f557592b24751f
Parents: e1edb7d
Author: Hans Zeller <hz...@apache.org>
Authored: Mon Jul 3 22:24:09 2017 +0000
Committer: Hans Zeller <hz...@apache.org>
Committed: Mon Jul 3 22:24:09 2017 +0000

----------------------------------------------------------------------
 core/sql/optimizer/HbaseSearchSpec.cpp | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/27b7671a/core/sql/optimizer/HbaseSearchSpec.cpp
----------------------------------------------------------------------
diff --git a/core/sql/optimizer/HbaseSearchSpec.cpp b/core/sql/optimizer/HbaseSearchSpec.cpp
index 66598ca..9ba70ee 100644
--- a/core/sql/optimizer/HbaseSearchSpec.cpp
+++ b/core/sql/optimizer/HbaseSearchSpec.cpp
@@ -103,12 +103,12 @@ static NABoolean extractKeyValuePairs(const NAString& source, NAString& result)
       // error, do not have enough buffer to read
       if ( end > tail )
         break;
-      NAString len;
-      source.extract(begin, end-1, len);
+      NAString tmp;
+      source.extract(begin, end-1, tmp);
   
       // get the string
       begin = end;
-      end = begin + (*(UInt16 *)(len.data()));
+      end = begin + (*(UInt16 *)(tmp.data()));
       // if the string lengh is 0, continue
       if ( end == begin) {
         header = end;
@@ -119,7 +119,10 @@ static NABoolean extractKeyValuePairs(const NAString& source, NAString& result)
       // error, do not have enough buffer to read
       else if ( end > tail )
         break;
-      source.extract(begin, end-1, result);
+      // add the new string but stop at any NUL characters
+      tmp.clear();
+      source.extract(begin, end-1, tmp);
+      result.append(tmp.data());
       header = end;
       if ( header < tail )
         result.append(",");


[2/2] incubator-trafodion git commit: Merge [TRAFODION-2675] Fix for seabase/TEST010 failure PR-1161

Posted by hz...@apache.org.
Merge [TRAFODION-2675] Fix for seabase/TEST010 failure PR-1161


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/72bf9b73
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/72bf9b73
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/72bf9b73

Branch: refs/heads/master
Commit: 72bf9b738ee77b24da60eb6d06bfcacc8746e957
Parents: e1edb7d 27b7671
Author: Hans Zeller <hz...@apache.org>
Authored: Tue Jul 4 02:47:26 2017 +0000
Committer: Hans Zeller <hz...@apache.org>
Committed: Tue Jul 4 02:47:26 2017 +0000

----------------------------------------------------------------------
 core/sql/optimizer/HbaseSearchSpec.cpp | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------