Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash when hooking NSURL #23

Open
623637646 opened this issue Nov 19, 2020 · 0 comments
Open

Crash when hooking NSURL #23

623637646 opened this issue Nov 19, 2020 · 0 comments

Comments

@623637646
Copy link

let object = NSURL.init(string: "https://www.google.com")!
let hook = try? object.hook(
    #selector(getter: NSURL.host),
    methodSignature: (@convention(c) (AnyObject, Selector) -> String).self,
    hookSignature: (@convention(block) (AnyObject) -> String).self) { store in { `self` in
    return "http://www.facebook.com"
        }
}
let host = object.host

Screenshot 2020-11-19 at 10 27 15 AM

it's similar with this issue. steipete/Aspects#177

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant