[asterisk-dev] [Code Review] 3593: astobj2: Additional refactoring to push impl specific code down into the impls.

rmudgett reviewboard at asterisk.org
Thu Jun 19 17:32:49 CDT 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/3593/#review12238
-----------------------------------------------------------



branches/12/main/astobj2_container.c
<https://reviewboard.asterisk.org/r/3593/#comment22327>

    This should be using the tag, file, line, and func parameters.
    
    if (tag) {
      __ao2_ref_debug(node->obj, -1, tag, file, line, func);
    } else {
      ao2_t_ref(node->obj, -1, "Remove obj from container");
    }



branches/12/main/astobj2_container.c
<https://reviewboard.asterisk.org/r/3593/#comment22329>

    fall through should be outside the conditional since it is not part of it.



branches/12/main/astobj2_container_private.h
<https://reviewboard.asterisk.org/r/3593/#comment22326>

    This is now unused.



branches/12/main/astobj2_container_private.h
<https://reviewboard.asterisk.org/r/3593/#comment22320>

    leftovers :)



branches/12/main/astobj2_hash.c
<https://reviewboard.asterisk.org/r/3593/#comment22321>

    These two functions can be moved back to reduce the diff.



branches/12/main/astobj2_hash.c
<https://reviewboard.asterisk.org/r/3593/#comment22322>

    stray blank change



branches/12/main/astobj2_rbtree.c
<https://reviewboard.asterisk.org/r/3593/#comment22323>

    stray blank change



branches/12/tests/test_astobj2.c
<https://reviewboard.asterisk.org/r/3593/#comment22324>

    Where this was before had an implied scope of the function.  Outside the function it now has an implied global scope.
    
    Should add doxygen to it.



branches/12/tests/test_astobj2.c
<https://reviewboard.asterisk.org/r/3593/#comment22325>

    Should add doxygen for what ITERATIONS means.


- rmudgett


On June 19, 2014, 4:26 p.m., George Joseph wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/3593/
> -----------------------------------------------------------
> 
> (Updated June 19, 2014, 4:26 p.m.)
> 
> 
> Review request for Asterisk Developers and rmudgett.
> 
> 
> Repository: Asterisk
> 
> 
> Description
> -------
> 
> Move some implementation specific code from astobj2_container.c into astobj2_hash.c and astobj2_rbtree.c.  This completely removes the need for astobj2_container to switch on RTTI and it no longer has any knowledge of the implementation details.  The RTTI itself is no longer needed but I don't want to remove it until weak reference containers are added in case I need it back again.  If not, I'll remove it then.
> 
> 
> Diffs
> -----
> 
>   branches/12/tests/test_astobj2.c 416802 
>   branches/12/main/astobj2_rbtree.c 416802 
>   branches/12/main/astobj2_private.h 416802 
>   branches/12/main/astobj2_hash.c 416802 
>   branches/12/main/astobj2_container_private.h 416802 
>   branches/12/main/astobj2_container.c 416802 
>   branches/12/build_tools/cflags.xml 416802 
> 
> Diff: https://reviewboard.asterisk.org/r/3593/diff/
> 
> 
> Testing
> -------
> 
> Ran all the test framework tests plus the "astobj2 test" test.
> Ran testsuite tests/channels/pjsip.
> 
> 
> Thanks,
> 
> George Joseph
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140619/014dcc4b/attachment-0001.html>


More information about the asterisk-dev mailing list