Skip to content

Instantly share code, notes, and snippets.

@moloch--
Created April 27, 2015 18:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save moloch--/068997969de1e45f1e0d to your computer and use it in GitHub Desktop.
Save moloch--/068997969de1e45f1e0d to your computer and use it in GitHub Desktop.
diff --git a/iSpy.web.xm b/iSpy.web.xm
index 1766687..9fa5bbd 100644
--- a/iSpy.web.xm
+++ b/iSpy.web.xm
@@ -193,7 +193,7 @@ static dispatch_queue_t wsQueue = dispatch_queue_create(WS_QUEUE, NULL);
// Requires C linkage for the msgSend stuff.
extern "C" {
void bf_websocket_write(const char *msg) {
- static iSpyWebSocket *syncSocket = [[[iSpy sharedInstance] webServer] iSpyWebSocket]; // static for speed/cache
+ static iSpyHTTPServer *httpServer = [[[iSpy sharedInstance] webServer] httpServer]; // static for speed/cache
NSString *json = orig_objc_msgSend(objc_getClass("NSString"), @selector(stringWithUTF8String:), msg);
// this async and almost immediately returns
@@ -201,7 +201,7 @@ extern "C" {
// be async
dispatch_async(wsQueue, ^{
- orig_objc_msgSend(syncSocket, @selector(sendMessage:), json);
+ orig_objc_msgSend(httpServer, @selector(ispySocketBroadcast:), json);
});
}
}
diff --git a/theos b/theos
--- a/theos
+++ b/theos
@@ -1 +1 @@
-Subproject commit 23df104fbd402fde35c0c43c3a959eb109c091ea
+Subproject commit 23df104fbd402fde35c0c43c3a959eb109c091ea-dirty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment