OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "webkit/appcache/appcache_update_job.h" | 5 #include "webkit/appcache/appcache_update_job.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
(...skipping 874 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
885 for (base::hash_set<std::string>::const_iterator it = | 885 for (base::hash_set<std::string>::const_iterator it = |
886 manifest.explicit_urls.begin(); | 886 manifest.explicit_urls.begin(); |
887 it != manifest.explicit_urls.end(); ++it) { | 887 it != manifest.explicit_urls.end(); ++it) { |
888 AddUrlToFileList(GURL(*it), AppCacheEntry::EXPLICIT); | 888 AddUrlToFileList(GURL(*it), AppCacheEntry::EXPLICIT); |
889 } | 889 } |
890 | 890 |
891 const std::vector<Namespace>& intercepts = | 891 const std::vector<Namespace>& intercepts = |
892 manifest.intercept_namespaces; | 892 manifest.intercept_namespaces; |
893 for (std::vector<Namespace>::const_iterator it = intercepts.begin(); | 893 for (std::vector<Namespace>::const_iterator it = intercepts.begin(); |
894 it != intercepts.end(); ++it) { | 894 it != intercepts.end(); ++it) { |
895 AddUrlToFileList(it->target_url, AppCacheEntry::INTERCEPT); | 895 int flags = AppCacheEntry::INTERCEPT; |
| 896 if (it->is_executable) |
| 897 flags |= AppCacheEntry::EXECUTABLE; |
| 898 AddUrlToFileList(it->target_url, flags); |
896 } | 899 } |
897 | 900 |
898 const std::vector<Namespace>& fallbacks = | 901 const std::vector<Namespace>& fallbacks = |
899 manifest.fallback_namespaces; | 902 manifest.fallback_namespaces; |
900 for (std::vector<Namespace>::const_iterator it = fallbacks.begin(); | 903 for (std::vector<Namespace>::const_iterator it = fallbacks.begin(); |
901 it != fallbacks.end(); ++it) { | 904 it != fallbacks.end(); ++it) { |
902 AddUrlToFileList(it->target_url, AppCacheEntry::FALLBACK); | 905 AddUrlToFileList(it->target_url, AppCacheEntry::FALLBACK); |
903 } | 906 } |
904 | 907 |
905 // Add all master entries from newest complete cache. | 908 // Add all master entries from newest complete cache. |
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1338 | 1341 |
1339 // Break the connection with the group so the group cannot call delete | 1342 // Break the connection with the group so the group cannot call delete |
1340 // on this object after we've posted a task to delete ourselves. | 1343 // on this object after we've posted a task to delete ourselves. |
1341 group_->SetUpdateStatus(AppCacheGroup::IDLE); | 1344 group_->SetUpdateStatus(AppCacheGroup::IDLE); |
1342 group_ = NULL; | 1345 group_ = NULL; |
1343 | 1346 |
1344 MessageLoop::current()->DeleteSoon(FROM_HERE, this); | 1347 MessageLoop::current()->DeleteSoon(FROM_HERE, this); |
1345 } | 1348 } |
1346 | 1349 |
1347 } // namespace appcache | 1350 } // namespace appcache |
OLD | NEW |