Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #249 from adobe/glenn/crash-on-refresh

Fix potential crash when reloading Brackets
  • Loading branch information...
commit f791fb90c9d8407ebda2b1753a5ee32b17eb404e 2 parents 8f31d92 + daaa041
Randy Edmunds redmunds authored
Showing with 4 additions and 1 deletion.
  1. +4 −1 appshell/client_app.cpp
5 appshell/client_app.cpp
View
@@ -161,7 +161,10 @@ class AppShellExtensionHandler : public CefV8Handler {
// Pass all messages to the browser process. Look in appshell_extensions.cpp for implementation.
CefRefPtr<CefBrowser> browser =
CefV8Context::GetCurrentContext()->GetBrowser();
- ASSERT(browser.get());
+ if (!browser.get()) {
+ // If we don't have a browser, we can't handle the command.
+ return false;
+ }
CefRefPtr<CefProcessMessage> message =
CefProcessMessage::Create(name);
CefRefPtr<CefListValue> messageArgs = message->GetArgumentList();
Please sign in to comment.
Something went wrong with that request. Please try again.