Commits

Christian Krebs committed 338c83a

call the message handler in the http interface in a try catch

  • Participants
  • Parent commits 0eb63e4

Comments (0)

Files changed (1)

templates/js/js-http-interface.mako

           '\n  payload: ' + xhr.responseText.replace(/([,.()])/g, '$1\u200b')
         );
       % endif
-      _receive_callback(service, message, command, status, tag);
+      try
+      {
+        _receive_callback(service, message, command, status, tag);
+      }
+      catch(e)
+      {
+        opera.postError(
+          'failed to handle message\n' +
+          '  service: ' + service + '\n' +
+          '  command: ' + command + '\n' +
+          '  message: ' + JSON.stringify(message)
+          )
+      }
     }
     _proxy.GET( "/get-message?time=" + new Date().getTime(), _receive_dragonkeeper);
   }