diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-12 21:53:16 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-12 21:53:16 +0000 |
commit | be13068b97a3aac41cad8a77f1b8626b29aaa934 (patch) | |
tree | 082bc2f007d41f6c79e5675a16d5c0f914ca8643 /base/native_library_win.cc | |
parent | a6152af0508075b978b4f73e1bd74f0e8cd3bb7f (diff) | |
download | chromium_src-be13068b97a3aac41cad8a77f1b8626b29aaa934.zip chromium_src-be13068b97a3aac41cad8a77f1b8626b29aaa934.tar.gz chromium_src-be13068b97a3aac41cad8a77f1b8626b29aaa934.tar.bz2 |
ThreadRestrictions: mark library loading functions as doing IO
Remove the hack we used for checking that plugins didn't
regress, as this is a generalization of that idea.
Review URL: http://codereview.chromium.org/4161004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@66003 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/native_library_win.cc')
-rw-r--r-- | base/native_library_win.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/base/native_library_win.cc b/base/native_library_win.cc index 94e4b63..b498eba 100644 --- a/base/native_library_win.cc +++ b/base/native_library_win.cc @@ -7,12 +7,16 @@ #include <windows.h> #include "base/file_util.h" +#include "base/thread_restrictions.h" #include "base/utf_string_conversions.h" namespace base { // static NativeLibrary LoadNativeLibrary(const FilePath& library_path) { + // LoadLibrary() opens the file off disk. + base::ThreadRestrictions::AssertIOAllowed(); + // Switch the current directory to the library directory as the library // may have dependencies on DLLs in this directory. bool restore_directory = false; |