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

Unified Diff: chrome/browser/extensions/extension_creator.cc

Issue 7618044: Fix a crash in the Extension Creator when crx is in use. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
« chrome/app/generated_resources.grd ('K') | « chrome/app/generated_resources.grd ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extension_creator.cc
===================================================================
--- chrome/browser/extensions/extension_creator.cc (revision 96544)
+++ chrome/browser/extensions/extension_creator.cc (working copy)
@@ -192,6 +192,10 @@
if (file_util::PathExists(crx_path))
file_util::Delete(crx_path, false);
ScopedStdioHandle crx_handle(file_util::OpenFile(crx_path, "wb"));
+ if (!crx_handle.get()) {
+ error_message_ = l10n_util::GetStringUTF8(IDS_EXTENSION_SHARING_VIOLATION);
+ return false;
+ }
std::vector<uint8> public_key;
if (!private_key->ExportPublicKey(&public_key)) {
« chrome/app/generated_resources.grd ('K') | « chrome/app/generated_resources.grd ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698