projects
/
dbsrgits/DBIx-Class-Historic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(parent:
be64931
)
Fix rogue child disconnecting a parent $dbh - no idea how I even missed that
Peter Rabbitson [Fri, 17 Feb 2012 11:54:09 +0000 (12:54 +0100)]
Changes
patch
|
blob
|
blame
|
history
lib/DBIx/Class/Storage/DBI.pm
patch
|
blob
|
blame
|
history
t/storage/global_destruction.t
patch
|
blob
|
blame
|
history
diff --git
a/Changes
b/Changes
index
85dc399
..
1e3dfbd
100644
(file)
--- a/
Changes
+++ b/
Changes
@@
-11,6
+11,8
@@
Revision history for DBIx::Class
instead
- Fix SkipFirst and FirstSkip limit dialects (Informix and Firebird)
- A number of corner case fixes of void context populate() with \[]
+ - Fix corner case of forked children disconnecting the parents DBI
+ handle
* Misc
- Codebase is now trailing-whitespace-free
diff --git
a/lib/DBIx/Class/Storage/DBI.pm
b/lib/DBIx/Class/Storage/DBI.pm
index
8abcc6e
..
7041e9d
100644
(file)
--- a/
lib/DBIx/Class/Storage/DBI.pm
+++ b/
lib/DBIx/Class/Storage/DBI.pm
@@
-230,6
+230,7
@@
sub DESTROY {
my $self = shift;
# some databases spew warnings on implicit disconnect
+ $self->_verify_pid;
local $SIG{__WARN__} = sub {};
$self->_dbh(undef);
diff --git
a/t/storage/global_destruction.t
b/t/storage/global_destruction.t
index
e92a3a6
..
ae4260a
100644
(file)
--- a/
t/storage/global_destruction.t
+++ b/
t/storage/global_destruction.t
@@
-53,6
+53,7
@@
for my $type (qw/PG MYSQL/) {
}
else {
note "Child $$ terminating";
+ undef $DBICTest::FakeSchemaFactory::schema;
exit 0;
}