From: Peter Rabbitson Date: Sat, 7 Dec 2013 05:53:00 +0000 (+0100) Subject: Augment 1363f0f5 for running in hell X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=00882d2c977e56a42654e8c5bb3cd02fde7921f5;p=dbsrgits%2FDBIx-Class-Historic.git Augment 1363f0f5 for running in hell SQLite produces extra warnings on Win32 even with an appropriate IV_SIZE --- diff --git a/lib/DBIx/Class/Storage/DBI/SQLite.pm b/lib/DBIx/Class/Storage/DBI/SQLite.pm index a1a84c0..18f87ae 100644 --- a/lib/DBIx/Class/Storage/DBI/SQLite.pm +++ b/lib/DBIx/Class/Storage/DBI/SQLite.pm @@ -257,7 +257,11 @@ sub bind_attribute_by_data_type { # DBD::SQLite warns on binding >32 bit values with 32 bit IVs sub _dbh_execute { if ( - DBIx::Class::_ENV_::IV_SIZE < 8 + ( + DBIx::Class::_ENV_::IV_SIZE < 8 + or + DBIx::Class::_ENV_::OS_NAME eq 'MSWin32' + ) and ! defined $DBD::SQLite::__DBIC_CHECK_dbd_mishandles_bound_BIGINT ) { @@ -272,7 +276,15 @@ sub _dbh_execute { | \d+ \s type \s @{[ DBI::SQL_BIGINT() ]} \s as \s [-+]? \d+ (?: \. 0*)? ) - /x ) if DBIx::Class::_ENV_::IV_SIZE < 8 and $DBD::SQLite::__DBIC_CHECK_dbd_mishandles_bound_BIGINT; + /x ) if ( + ( + DBIx::Class::_ENV_::IV_SIZE < 8 + or + DBIx::Class::_ENV_::OS_NAME eq 'MSWin32' + ) + and + $DBD::SQLite::__DBIC_CHECK_dbd_mishandles_bound_BIGINT + ); shift->next::method(@_); } diff --git a/lib/DBIx/Class/_Util.pm b/lib/DBIx/Class/_Util.pm index 7430dfd..cf7443f 100644 --- a/lib/DBIx/Class/_Util.pm +++ b/lib/DBIx/Class/_Util.pm @@ -35,6 +35,8 @@ BEGIN { ASSERT_NO_INTERNAL_WANTARRAY => $ENV{DBIC_ASSERT_NO_INTERNAL_WANTARRAY} ? 1 : 0, IV_SIZE => $Config{ivsize}, + + OS_NAME => $^O, }; if ($] < 5.009_005) {