You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by "Keith Turner (JIRA)" <ji...@apache.org> on 2014/02/10 21:31:25 UTC

[jira] [Resolved] (ACCUMULO-2131) while statement used as if statement

     [ https://issues.apache.org/jira/browse/ACCUMULO-2131?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Keith Turner resolved ACCUMULO-2131.
------------------------------------

    Resolution: Not A Problem

> while statement used as if statement
> ------------------------------------
>
>                 Key: ACCUMULO-2131
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-2131
>             Project: Accumulo
>          Issue Type: Bug
>          Components: tserver
>            Reporter: Eric Newton
>            Assignee: Keith Turner
>            Priority: Trivial
>             Fix For: 1.6.0
>
>
> Going through PMD output, and this looks a little sketchy in SourceSwitchingIterator.java:
> {noformat}
>   private boolean switchSource() throws IOException {
>     while (!source.isCurrent()) {
>       source = source.getNewDataSource();
>       iter = source.iterator();
>       if (iflag != null)
>         ((InterruptibleIterator) iter).setInterruptFlag(iflag);
>       
>       return true;
>     }
>     
>     return false;
>   }
> {noformat}
> I'm wondering if that "while" should be "if"



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)