if (this.debug) {
System.err.println("READ NULL RECORD");
}
this.hasHitEOF = true;
if (this.buffer.isEOFRecord(headerBuf)) {
if (this.debug) {
System.err.println("READ EOF RECORD");
}
this.hasHitEOF = true;
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/tar/TarInputStream.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/tar/TarInputStream.java
|
Method name: TarEntry getNextEntry()
|
|
Method name: TarEntry getNextEntry()
|
Number of AST nodes: 3
|
|
Number of AST nodes: 4
|
|
| | | 1 | if (this.buffer.isEOFRecord(headerBuf)) {↵
|
1 | if (this.debug) {↵ | | 2 | if (this.debug) {↵
|
2 | System.err.println("READ NULL RECORD");↵ | | 3 | System.err.println("READ EOF RECORD");↵
|
3 | }↵ | | 4 | }↵
|
4 | this.hasHitEOF = true; | | 5 | this.hasHitEOF = true;↵
|
| | | 6 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 6 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 3 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 1.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
12 | if (this.debug) | | 16 | if (this.debug) |
13 | System.err.println("READ NULL RECORD"); | | 17 | System.err.println("READ EOF RECORD"); |
14 | this.hasHitEOF = true; | | 18 | this.hasHitEOF = true; |
Precondition Violations (0)
Row |
Violation |