trafodion-codereview mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From DaveBirdsall <...@git.apache.org>
Subject [GitHub] trafodion pull request #1557: Changes for [TRAFODION-3065] and [TRAFODION-29...
Date Wed, 09 May 2018 21:19:51 GMT
Github user DaveBirdsall commented on a diff in the pull request:

    https://github.com/apache/trafodion/pull/1557#discussion_r187179351
  
    --- Diff: core/sql/src/main/java/org/trafodion/sql/HDFSClient.java ---
    @@ -151,10 +180,38 @@ public Object call() throws IOException
                 bufOffset_ += bytesRead;
                 pos_ += bytesRead;
                 lenRemain_ -= bytesRead;
    -         } while (lenRemain_ > 0);
    +         } while (lenRemain_ > 0); 
              return new Integer(totalBytesRead);
           }
    -   }
    +    } 
    +
    +    int compressedFileRead(int readLenRemain) throws IOException 
    +    {
    +       int totalReadLen = 0;
    +       int readLen;
    +       int offset = 0;
    +       int retcode;
    +
    +         int lenRemain = ((readLenRemain > bufArray_.length) ? bufArray_.length :
readLenRemain);
    --- End diff --
    
    What happens if readLenRemain is zero or negative on entry?


---

Mime
View raw message