Git Product home page Git Product logo

Comments (5)

atmaxinger avatar atmaxinger commented on April 28, 2024

Seems like you're trying to build the game with the Debug configuratipn. Switch to Release build. The settings for the Debug build are a bit over restrictive.

from openrct2.

duncanspumpkin avatar duncanspumpkin commented on April 28, 2024

Although saying that there is a good point that widget will potentially be not initialized see line 520 (input_mouseover). I think there should probably be an else return but i would have to check the original code. Same for the other function at line 621 (input_leftmousedown). These will need to be fixed at some point so don't close the bug.

from openrct2.

Gymnasiast avatar Gymnasiast commented on April 28, 2024

Does this still apply to the current code?

from openrct2.

janisozaur avatar janisozaur commented on April 28, 2024

The code has moved to https://github.com/OpenRCT2/OpenRCT2/blob/develop/src/input.c#L798 and I don't think this warning is valid. I ceratinly haven't seen it with clang/gcc compiles.

in line 798 widget is declared without explicit assignment, in line 800 if (w != NULL) then in line 803 widget has value assigned. In line 808, which was previously 526 mentioned in original report, there is a check if (w != NULL && widgetIndex != -1 && widget->type == WWT_SCROLL) which dereferences widget if and only if w != NULL, which guaranteed value assignment in line 803 above.

An assert could be added just after assignment in line 803 to see if widget is not NULL, but otherwise it looks fine.

from openrct2.

Gymnasiast avatar Gymnasiast commented on April 28, 2024

Considering the changes since 2014 and janisozaur's comment I'll assume this no longer applies to the current state of the code.

from openrct2.

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.