[ 
https://issues.apache.org/jira/browse/HDFS-7807?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14326428#comment-14326428
 ] 

Chris Nauroth commented on HDFS-7807:
-------------------------------------

Hi Colin.  This looks good.  A few small comments:

# {{round_up_to_power_of_2}} does not return a power of 2 for i == 0.  However, 
we don't need it to, because we separately enforce {{HTABLE_MIN_SIZE}} of 4.  
Maybe just drop a quick comment here to prevent confusion?
# On Windows, the compiler spews a bunch of type cast and loss of precision 
warnings on the test code.  This is really just a side effect of manually 
setting void pointer values to stub the keys and values for the tests.  I think 
it's acceptable to stifle the warnings by adding the following right before 
{{main}}:
{code}
// Disable type cast and loss of precision warnings, because the test 
manipulates
// void* values manually on purpose.
#ifdef WIN32
#pragma warning(disable: 4244 4306)
#endif
{code}

Thanks!

> libhdfs htable.c: fix htable resizing, add unit test
> ----------------------------------------------------
>
>                 Key: HDFS-7807
>                 URL: https://issues.apache.org/jira/browse/HDFS-7807
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: native
>    Affects Versions: 2.7.0
>            Reporter: Colin Patrick McCabe
>            Assignee: Colin Patrick McCabe
>         Attachments: HDFS-7807.001.patch
>
>
> libhdfs htable.c: fix htable resizing, add unit test



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to