try { conn.close(); } catch (SQLException ex) { // i18n[ConnectToAliasCommand.error.closeconnection=Error occured closing Connection] s_log.error(s_stringMgr.getString("ConnectToAliasCommand.error.closeconnection"), ex); }
if (fos != null) { try { fos.close(); } catch (IOException ex) { s_log.error("Unable to close output stream: "+ex.getMessage(), ex); } }
Clone fragments detected by clone detection tool
File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/mainframe/action/ConnectToAliasCommand.java File path: /sql12/plugins/sqlbookmark/src/net/sourceforge/squirrel_sql/plugins/sqlbookmark/SQLBookmarkPlugin.java
Method name: void closeConnection(ISQLConnection) Method name: void saveBookmarkProperties()
Number of AST nodes: 2 Number of AST nodes: 3
1
try
2
				{
3
					conn.close();
4
				}
5
				
1
if (fos != null) {
2
              try {
3
                  fos.close();
6
catch (SQLException ex)
4
              } catch (IOException ex)
7
				{
8
  
5
 {
9
                  // i18n[ConnectToAliasCommand.error.closeconnection=Error occured closing Connection]
6
                  
10
					s_log.error(s_stringMgr.getString("ConnectToAliasCommand.error.closeconnection"), ex);
11
				
7
s_log.error("Unable to close output stream: "+ex.getMessage(),
8
                              ex);
9
              }
12
}
10
          }
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in different classes
Number of node comparisons0