Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(126)

Side by Side Diff: Source/modules/webdatabase/sqlite/SQLiteDatabase.cpp

Issue 210853002: Oilpan: Prepare to move DatabaseAuthorizer to Oilpan heap. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/modules/webdatabase/sqlite/SQLiteDatabase.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2007 Justin Haygood (jhaygood@reaktix.com) 3 * Copyright (C) 2007 Justin Haygood (jhaygood@reaktix.com)
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 return auth->dropVTable(parameter1, parameter2); 356 return auth->dropVTable(parameter1, parameter2);
357 case SQLITE_FUNCTION: 357 case SQLITE_FUNCTION:
358 return auth->allowFunction(parameter2); 358 return auth->allowFunction(parameter2);
359 #endif 359 #endif
360 default: 360 default:
361 ASSERT_NOT_REACHED(); 361 ASSERT_NOT_REACHED();
362 return SQLAuthDeny; 362 return SQLAuthDeny;
363 } 363 }
364 } 364 }
365 365
366 void SQLiteDatabase::setAuthorizer(PassRefPtr<DatabaseAuthorizer> auth) 366 void SQLiteDatabase::setAuthorizer(DatabaseAuthorizer* auth)
367 { 367 {
368 if (!m_db) { 368 if (!m_db) {
369 WTF_LOG_ERROR("Attempt to set an authorizer on a non-open SQL database") ; 369 WTF_LOG_ERROR("Attempt to set an authorizer on a non-open SQL database") ;
370 ASSERT_NOT_REACHED(); 370 ASSERT_NOT_REACHED();
371 return; 371 return;
372 } 372 }
373 373
374 MutexLocker locker(m_authorizerLock); 374 MutexLocker locker(m_authorizerLock);
375 375
376 m_authorizer = auth; 376 m_authorizer = auth;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
415 default: 415 default:
416 if (!executeCommand("PRAGMA auto_vacuum = 2")) 416 if (!executeCommand("PRAGMA auto_vacuum = 2"))
417 return false; 417 return false;
418 runVacuumCommand(); 418 runVacuumCommand();
419 error = lastError(); 419 error = lastError();
420 return (error == SQLITE_OK); 420 return (error == SQLITE_OK);
421 } 421 }
422 } 422 }
423 423
424 } // namespace WebCore 424 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/modules/webdatabase/sqlite/SQLiteDatabase.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698