Skip to content

One of the New3CommandStatus values is out of range (silently truncated) #4253

@RafalSzefler

Description

@RafalSzefler

NotFound = unchecked((int)0x800200006),

This number has 36 bits (coincidentally 36th line as well 😉). It doesn't fit in int and thus is truncated (silently, thanks to unchecked) to 0x200006. Since none of the other status codes in this file actually overflows, I assume it is a mistake. Likely there should've been one less zero inside 200006. As a side effect, this is the only error code that is actually positive.

I'm not sure if it is doable to fix that, I mean such change is not backwards compatible: even though the enum is internal, those codes actually leak outside (I've seen it in console, that's where I started to search for it). But this actually makes debugging a bit hard, since the reported error code is not present in the code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    triagedThe issue was evaluated by the triage team, placed on correct area, next action defined.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions