cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Darren Shepherd" <darren.s.sheph...@gmail.com>
Subject Re: Review Request 13938: StringUtils csv methods simplified
Date Fri, 04 Oct 2013 17:24:29 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/13938/#review26676
-----------------------------------------------------------



utils/src/com/cloud/utils/StringUtils.java
<https://reviews.apache.org/r/13938/#comment51962>

    This is not actually correct, the previous code would do a trim() and the new code also
can introduce a NPE.  So check for null and return empty list, also the following snippet
deals well with white space
    
    tags.trim().split("\\s*,\\s*")


- Darren Shepherd


On Sept. 3, 2013, 7:22 a.m., Laszlo Hornyak wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/13938/
> -----------------------------------------------------------
> 
> (Updated Sept. 3, 2013, 7:22 a.m.)
> 
> 
> Review request for cloudstack and Prachi Damle.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> - longer method bodies replaced with oneliners
> - tests added to ensure compatibility
> 
> 
> Diffs
> -----
> 
>   utils/src/com/cloud/utils/StringUtils.java 948c0ac 
>   utils/test/com/cloud/utils/StringUtilsTest.java ae37c24 
> 
> Diff: https://reviews.apache.org/r/13938/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Laszlo Hornyak
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message