Giter VIP home page Giter VIP logo

hardshell's Introduction

HardShell

HardShell is a protector to keep app from specific crashes. Now it only protects app from the crash caused by "unrecognized selector sent to instance". More features will come step by step.

The idea is from Baymax's introduction which is from Wangyi (Hangzhou). They promise Baymax SDK will be released but don't mention the schedule and if it will be opensourced. So I build HardShell.

It is still at early stages and not product ready to launch. Please help me to do more testing. Pull requests are always highly welcomed.

unrecognized selector crash

The following code will crash you app because of “unrecognized selector crash” which is very popular in iOS apps.

    UIButton *button = [[UIButton alloc] init];
    [button performSelector:@selector(noThisMethod:)];

HardShell will protect it from this crash. Let’s show before and after.

Before:

After:

The crash disappeared and the root cause is shown.

KVO crash

  1. add same observer repeatedly for same key path
  2. remove same observation repeatedly
  3. remove nonexistent observation For example:

Other features will come soon.

License

This code is distributed under the terms and conditions of the MIT license.

Thanks

Great idea from Baymax of Wangyi (Hangzhou).

hardshell's People

Contributors

nilstack avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.