if( gs >= m_nMTF ) { break; } ge = gs + G_SIZE - 1; if( ge >= m_nMTF ) { ge = m_nMTF - 1; }
if( gs >= m_nMTF ) { break; } ge = gs + G_SIZE - 1; if( ge >= m_nMTF ) { ge = m_nMTF - 1; }
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/installer/CBZip2OutputStream.java File path: /jEdit-4.2/src/installer/CBZip2OutputStream.java
Method name: void sendMTFValues() Method name: void sendMTFValues()
Number of AST nodes: 5 Number of AST nodes: 5
1
if( gs >= m_nMTF )
1
if( gs >= m_nMTF )
2
                {
2
            
3
    
3
{
4
                break;
4
                break;
5
                }
5
            
6
    
6
}
7
            ge = gs + G_SIZE - 1;
7
            ge = gs + G_SIZE - 1;
8
                if( ge >= m_nMTF )
8
            if( ge >= m_nMTF )
9
                {
9
            {
10
                    ge = m_nMTF - 1;
10
                ge = m_nMTF - 1;
11
                }
11
            }
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.4
Clones locationClones are in the same method
Number of node comparisons26
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements5
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)1.9
    Clone typeType 1
    Mapped Statements
    ID Statement ID Statement
    68
    if (gs >= m_nMTF)
    189
    if (gs >= m_nMTF)
    69
    break;
    69
    break;
    190
    break;
    Preondition Violations
    Statement break; without innermost loop
    Statement break; without innermost loop
    190
    break;
    70
    ge = gs + G_SIZE - 1;
    191
    ge = gs + G_SIZE - 1;
    71
    if (ge >= m_nMTF)
    192
    if (ge >= m_nMTF)
    72
    ge = m_nMTF - 1;
    193
    ge = m_nMTF - 1;
    Precondition Violations (2)
    Row Violation
    1Statement break; without innermost loop
    2Statement break; without innermost loop