Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-47717

QTime::addSecs can overflow

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3: Somewhat important
    • Resolution: Done
    • Affects Version/s: 5.5.0
    • Fix Version/s: 5.5.1
    • Component/s: Core: Date/Time
    • Labels:
      None
    • Environment:
      windows 7 32 bit
    • Commits:
      cc5e84c8788a6d6f05dfdf76fc249177ee74dce1

      Description

      The following ends up in 03:28:36 but should be 20:31:24.
      QTime time;
      time.setHMS(0,0,0);
      time = time.addSecs(2233884);

      QLabel label;
      label.setText(time.toString("hh:mm:ss"));
      label.show();

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            thiago Thiago Macieira
            Reporter:
            tobske Tobias Matern
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes