mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:17:36 +00:00
Browser: Check m_console_client is non-null before dereferencing it
This added check matches CientConnection::js_console_input and makes sure the webcontent process doesn't crash if the console is opened while no page is available (like in a file not found situation)
This commit is contained in:
parent
10d4f2fc1e
commit
890d5e45ee
1 changed files with 2 additions and 1 deletions
|
@ -317,7 +317,8 @@ void ClientConnection::run_javascript(String const& js_source)
|
|||
|
||||
void ClientConnection::js_console_request_messages(i32 start_index)
|
||||
{
|
||||
m_console_client->send_messages(start_index);
|
||||
if (m_console_client)
|
||||
m_console_client->send_messages(start_index);
|
||||
}
|
||||
|
||||
Messages::WebContentServer::GetSelectedTextResponse ClientConnection::get_selected_text()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue