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

QAuthenticator operator== crashes

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P1: Critical
    • Resolution: Done
    • Affects Version/s: 5.6.0
    • Fix Version/s: 5.6.2, 5.7.0
    • Labels:
      None
    • Commits:
      b8b732b9c65c02ee542885e5d6fe9bd1589a6b1a

      Description

      This simple scenario leads to AV:

       QAuthenticator s1, s2;
       s1.setUser("User");
       if (s2 == s1) {}
      

      Reason is QAuthenticator::operator== implementation:

      bool QAuthenticator::operator==(const QAuthenticator &other) const
      {
          if (d == other.d)
              return true;
          return d->user == other.d->user
              && d->password == other.d->password
              && d->realm == other.d->realm
              && d->method == other.d->method
              && d->options == other.d->options;
      }
      

      In this scenario d is null.

        Attachments

        For Gerrit Dashboard: QTBUG-53338
        # Subject Branch Project Status CR V

          Activity

            People

            Assignee:
            jefernan Jesus Fernandez
            Reporter:
            greydemonstr Sergey Ivanov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes