Giter Club home page Giter Club logo

Comments (5)

frispete avatar frispete commented on July 20, 2024 1

Hey, Doug, you're my hero of the day!

Thank you so much. Your approach to stick with signed chars and deal with the fallout is far superior to anything else.

from detox.

dharple avatar dharple commented on July 20, 2024

Thanks. I've noticed similar warnings from Clang (on Travis) and CLion. I'll address this in an upcoming release.

Unfortunately, most of the standard C functions take signed chars as their inputs, and the character transliteration logic in detox needs unsigned chars to work properly.

The code works with the implicit casts; I'll probably go with explicit casts in the v1 series and introduce more breaking changes in a major release.

from detox.

dharple avatar dharple commented on July 20, 2024

Yeah, this is big, and potentially breaking. I'll address it in v2.0.0.

from detox.

frispete avatar frispete commented on July 20, 2024

I feel with you.

My C brain is rusty at best, but maybe a set of wrapper macros/functions for the standard c functions with the correct casts in place would be the shortest path to success.

from detox.

dharple avatar dharple commented on July 20, 2024

Thanks @frispete ! I looked at your suggestion of creating wrappers around the standard C library, too, but ended up going with this approach when I realized it was only one of the filters that was failing, and I could fix it easily.

I also incorporated some of the gcc flags I saw from your output, adding protections against overflows and overruns. I like those a lot.

Thank you very much for the push in the right direction!

from detox.

Related Issues (20)

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.