diff options
author | yongsheng.zhu@intel.com <yongsheng.zhu@intel.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-08-31 05:27:16 +0000 |
---|---|---|
committer | yongsheng.zhu@intel.com <yongsheng.zhu@intel.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-08-31 05:27:16 +0000 |
commit | b18eb17489cff5e45d418ebc2de4075c4bdd7d50 (patch) | |
tree | b5950a8c67250a15ea182dd34f81168731908ed0 /base/files/file_path_watcher_linux.cc | |
parent | fc25aebc657d42e3aab852e28d51cdf68ad99f05 (diff) | |
download | chromium_src-b18eb17489cff5e45d418ebc2de4075c4bdd7d50.zip chromium_src-b18eb17489cff5e45d418ebc2de4075c4bdd7d50.tar.gz chromium_src-b18eb17489cff5e45d418ebc2de4075c4bdd7d50.tar.bz2 |
Enable file path watcher for Android
Use the linux implementation for file path watcher because
Android supports 'inotify'. This fixes the failed case
UserStyleSheetWatcherTest.StyleLoad.
BUG=139412
TEST=run_tests.py -s unit_tests
Review URL: https://chromiumcodereview.appspot.com/10874083
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@154387 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/files/file_path_watcher_linux.cc')
-rw-r--r-- | base/files/file_path_watcher_linux.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/base/files/file_path_watcher_linux.cc b/base/files/file_path_watcher_linux.cc index 205a3eb..d77b039 100644 --- a/base/files/file_path_watcher_linux.cc +++ b/base/files/file_path_watcher_linux.cc @@ -373,10 +373,10 @@ bool FilePathWatcherImpl::Watch(const FilePath& path, std::vector<FilePath::StringType> comps; target_.GetComponents(&comps); DCHECK(!comps.empty()); - for (std::vector<FilePath::StringType>::const_iterator comp(++comps.begin()); - comp != comps.end(); ++comp) { + std::vector<FilePath::StringType>::const_iterator comp = comps.begin(); + for (++comp; comp != comps.end(); ++comp) watches_.push_back(WatchEntry(InotifyReader::kInvalidWatch, *comp)); - } + watches_.push_back(WatchEntry(InotifyReader::kInvalidWatch, FilePath::StringType())); return UpdateWatches(); |