| Index: Source/web/WebDevToolsFrontendImpl.cpp | 
| diff --git a/Source/web/WebDevToolsFrontendImpl.cpp b/Source/web/WebDevToolsFrontendImpl.cpp | 
| index 44dcaee0d6183ebd56c796fe5ab4040d99fa1a8a..7cc3dec68ad527d9f89e144f1907a4423778c4ed 100644 | 
| --- a/Source/web/WebDevToolsFrontendImpl.cpp | 
| +++ b/Source/web/WebDevToolsFrontendImpl.cpp | 
| @@ -93,8 +93,15 @@ void WebDevToolsFrontendImpl::didClearWindowObject(WebLocalFrameImpl* frame) | 
|  | 
| String origin = frame->securityOrigin().toString(); | 
| String script = m_injectedScriptForOrigin.get(origin); | 
| -    if (!script.isEmpty()) | 
| -        frame->frame()->script().executeScriptInMainWorld(script + "()"); | 
| +    if (script.isEmpty()) | 
| +        return; | 
| +    static int s_lastScriptId = 0; | 
| +    StringBuilder scriptWithId; | 
| +    scriptWithId.append(script); | 
| +    scriptWithId.append('('); | 
| +    scriptWithId.appendNumber(++s_lastScriptId); | 
| +    scriptWithId.append(')'); | 
| +    frame->frame()->script().executeScriptInMainWorld(scriptWithId.toString()); | 
| } | 
|  | 
| void WebDevToolsFrontendImpl::sendMessageToBackend(const String& message) | 
|  |