Revision 510
trunk/org.gvsig.postgresql/org.gvsig.postgresql.provider/src/main/java/org/gvsig/postgresql/dal/PostgreSQLBuilder.java | ||
---|---|---|
60 | 60 |
|
61 | 61 |
public Version getDatabaseVersion() { |
62 | 62 |
if( databaseVersion == null ) { |
63 |
Connection conn; |
|
63 |
Connection conn = null;
|
|
64 | 64 |
try { |
65 | 65 |
conn = this.getHelper().getConnection(); |
66 | 66 |
DatabaseMetaData metadata = conn.getMetaData(); |
... | ... | |
70 | 70 |
); |
71 | 71 |
} catch (Exception ex) { |
72 | 72 |
databaseVersion = new Version(0,0); |
73 |
} finally { |
|
74 |
this.getHelper().closeConnectionQuietly(conn); |
|
73 | 75 |
} |
74 | 76 |
} |
75 | 77 |
return databaseVersion; |
Also available in: Unified diff