Coverity analysis defect 151472: Overflowed constant

XMLWordPrintableJSON

    • Storage Execution
    • Fully Compatible
    • ALL
    • v8.0
    • Storage Execution 2025-08-04
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Overflowed constant

      The overflowed value due to arithmetic on constants is too small or unexpectedly negative, causing incorrect computations. Integer overflow occurs in arithmetic on constant operands
      /src/mongo/db/storage/key_string.cpp:938: INTEGER_OVERFLOW 151472 Expression "0xffffffffffffffffUL << fractionalBits", which is equal to 18437736874454810624, where "fractionalBits" is known to be equal to 53, overflows the type that receives it, an unsigned integer 64 bits wide.

            Assignee:
            Wei Hu
            Reporter:
            Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: