[libpostgresql-jdbc-java] 04/24: Don't prevented VM shutdown if ConnectThread is blocked
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Mon Jan 9 21:17:39 UTC 2017
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to tag REL9_3_1103
in repository libpostgresql-jdbc-java.
commit 19fe4a8586193358566c04c1ad77e6f86576321c
Author: Dave Cramer <dave.cramer at credativ.ca>
Date: Mon Sep 1 12:25:40 2014 +0000
Don't prevented VM shutdown if ConnectThread is blocked
---
org/postgresql/Driver.java.in | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/org/postgresql/Driver.java.in b/org/postgresql/Driver.java.in
index 96a4be7..416ef18 100644
--- a/org/postgresql/Driver.java.in
+++ b/org/postgresql/Driver.java.in
@@ -280,7 +280,9 @@ public class Driver implements java.sql.Driver
return makeConnection(url, props);
ConnectThread ct = new ConnectThread(url, props);
- new Thread(ct, "PostgreSQL JDBC driver connection thread").start();
+ Thread thread = new Thread(ct, "PostgreSQL JDBC driver connection thread");
+ thread.setDaemon(true); // Don't prevent the VM from shutting down
+ thread.start();
return ct.getResult(timeout);
}
catch (PSQLException ex1)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/libpostgresql-jdbc-java.git
More information about the pkg-java-commits
mailing list