diff options
author | Noel Grandin <noel@peralex.com> | 2015-10-16 13:14:41 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-10-16 13:54:45 +0200 |
commit | fa2a7665194c7fff311d14932ee7930f80e6c7e2 (patch) | |
tree | 5bcd90c760ccf391bec2dbca03cca17ae60fe492 | |
parent | 7320072e3b49e39528e2ec9e51aa777eaff31031 (diff) |
cid#1326341 Unguarded read
Change-Id: Id49af9bc1c767126a365d85589fb4f2a99e5bcdd
-rw-r--r-- | qadevOOo/runner/util/db/DataSource.java | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/qadevOOo/runner/util/db/DataSource.java b/qadevOOo/runner/util/db/DataSource.java index 9b1ac806ff4c..e2fdcb9186de 100644 --- a/qadevOOo/runner/util/db/DataSource.java +++ b/qadevOOo/runner/util/db/DataSource.java @@ -64,13 +64,10 @@ public class DataSource /** * retrieves the css.sdb.OfficeDatabaseDocument associated with the data source */ - public DatabaseDocument getDatabaseDocument() + public synchronized DatabaseDocument getDatabaseDocument() { - synchronized ( this ) - { - if ( m_document == null ) - m_document = new DatabaseDocument( this ); - } + if ( m_document == null ) + m_document = new DatabaseDocument( this ); return m_document; } |