View | Details | Raw Unified | Return to bug 148318
Collapse All | Expand All

(-)Slim/Schema.pm (-1 / +5 lines)
Lines 274-284 Link Here
274
	# For custom exceptions
274
	# For custom exceptions
275
	$class->storage_type('Slim::Schema::Storage');
275
	$class->storage_type('Slim::Schema::Storage');
276
	
276
	
277
	# Don't use autocommit mode for the scanner.
278
	# Needs to be set here as setting dbh->{'AutoCommit'} = 0 later
279
	# confusing the transaction nesting logic.
280
	my $AutoCommit = (main::SCANNER ? 0 : 1);
277
	my $on_connect_do = $sqlHelperClass->on_connect_do();
281
	my $on_connect_do = $sqlHelperClass->on_connect_do();
278
	
282
	
279
	$class->connection( $dsn || $source, $username, $password, { 
283
	$class->connection( $dsn || $source, $username, $password, { 
280
		RaiseError    => 1,
284
		RaiseError    => 1,
281
		AutoCommit    => 1,
285
		AutoCommit    => $AutoCommit, 
282
		PrintError    => 0,
286
		PrintError    => 0,
283
		Taint         => 1,
287
		Taint         => 1,
284
		on_connect_do => [
288
		on_connect_do => [
(-)scanner.pl (-3 lines)
Lines 236-244 Link Here
236
236
237
	main::INFOLOG && $log->info("Squeezebox Server Scanner done init...\n");
237
	main::INFOLOG && $log->info("Squeezebox Server Scanner done init...\n");
238
238
239
	# Take the db out of autocommit mode - this makes for a much faster scan.
240
	Slim::Schema->storage->dbh->{'AutoCommit'} = 0;
241
242
	my $scanType = 'SETUP_STANDARDRESCAN';
239
	my $scanType = 'SETUP_STANDARDRESCAN';
243
240
244
	if ($wipe) {
241
	if ($wipe) {

Return to bug 148318