1. 25 Oct, 2020 1 commit
    • Alexander Potashev's avatar
      Fix bug: Some user profile fields won't apply unless they all have unique new values. · 3308dee9
      Alexander Potashev authored
      Fixes the following bug: Some user profile fields won't apply unless
      they all have unique new values.
      
      STEPS TO REPRODUCE
      1. Start the Users KCM ("kcmshell5 kcm_users")
      2. Select a user
      3. Change the full name (the top-most input field) to "foo", change the
         email address to "foo@example.com", click Apply.
      4. Restart the Users KCM and make sure the change applied.
      5. Change the full name to "bar@example.com", change the email address
         to "bar@example.com" as well, click Apply.
      
      OBSERVED RESULT: The full name remains "foo", the email address is
      changed to "bar@example.com".
      
      EXPECTED RESULT: Both fields should change to "bar@example.com".
      
      Root cause: When the std::map used in UserApplyJob::start() is
      initialized, the key-value {"bar@example.com", full name setter ptr} is
      being overwritten by key-value {"bar@example.com", email setter ptr}.
      
      BUG: 427348
      
      
      (cherry picked from commit 5cdff962)
      3308dee9
  2. 05 Oct, 2020 2 commits
    • David Redondo's avatar
      Remove fallthrough attribute · 43c7e301
      David Redondo authored
      I used it wrong and is actually not needed here
      GIT_SILENT
      
      
      (cherry picked from commit 1e13208c)
      43c7e301
    • David Redondo's avatar
      Add some rudimentary error handling to users kcm · 85000464
      David Redondo authored
      Don't fail silently when an error occurs otherwise the kcm just looks broken.
      Show at least an inline message so the user knows that something went wrong.
      The comment was wrong. We can distinguish why an error occured. Furthermore,
      even if it is a permission denied error we do not know if the user canceled
      the action or if it failed for some other reason so also treat that as an
      error.
      BUG:425036
      CCBUG:426932
      FIXED-IN:5.20
      CCMAIL:uhhadd@gmail.com
      
      
      (cherry picked from commit 05768142)
      85000464
  3. 05 Aug, 2020 1 commit
  4. 30 Jul, 2020 1 commit
  5. 08 Jun, 2020 1 commit
    • Adriaan de Groot's avatar
      Handle absent <crypt.h> · 3df00f81
      Adriaan de Groot authored
      The prototype for crypt(3) is in <unistd.h> on Linux and FreeBSD.
      The <crypt.h> header isn't needed at all. There's also machinery
      for detecting the presence of <crypt.h>, defining HAVE_CRYPT_H,
      but we don't need that.
      
      Reported and resolved independently in
      	https://phabricator.kde.org/D29847
      
      @nicofe tested that this works on Linux
      @adridg tested that this works on FreeBSD
      3df00f81
  6. 07 Jun, 2020 3 commits
    • Adriaan de Groot's avatar
      Normalize include-quotes · 59317865
      Adriaan de Groot authored
      - from local directory, use "" (esp. the header file for this .cpp)
      59317865
    • Adriaan de Groot's avatar
      Correct salting array: · bdca8c01
      Adriaan de Groot authored
      - Missing letter "w" and "W" in list of characters meant only 62
        letters, so less than 6 bits of randomness per salt char.
      - A char array like this one still has a trailing NUL char which
        affects the sizeof. Since bounded produces a number < its second
        argument, need to discount the NUL so we only index into
        the letters-part of the string.
      
      Add static_assert() to catch this.
      bdca8c01
    • Adriaan de Groot's avatar
      Sanitize saltCharacter() · 6b822924
      Adriaan de Groot authored
       - the array of salt chars should be const, it's read-only
       - the array of salt chars should be static, since it is
         initialized to a constant value anyway and can live beyond
         this one function
       - sizeof(char) is 1 by the standard, so remove the weird
         array-size calculation: here saltCharacters has type
         (const) char[63], and its sizeof() is 63
      6b822924
  7. 27 May, 2020 1 commit
    • Harald Sitter's avatar
      make bounded() unambiguous · 0cfda413
      Harald Sitter authored
      ```
      std::size_t is the unsigned integer type of the result of the sizeof
      operator
      ```
      
      this can make the bounded call ambiguous as it either sports
      an int(int,int) signature or an quint32(quint32,quint32) signature. with
      size_t being unsigned and 0 being int it's not necessarily clear to the
      compiler which overload to use, so make it clear by using usigned
      everywhere.
      this specifically fixes arm32 compatibility on ubuntu 20.04
      0cfda413
  8. 26 May, 2020 1 commit
    • Adriaan de Groot's avatar
      Remove spurious Q_EMIT · 8be74e64
      Adriaan de Groot authored
      This Q_EMIT has wandered in from somewhere else; it's not a
      syntax error because Q_EMIT is defined to empty, but it looks
      weird and misplaced.
      8be74e64
  9. 23 May, 2020 1 commit
    • Aleix Pol Gonzalez's avatar
      --warnings · b1c3af20
      Aleix Pol Gonzalez authored
      Port away from some deprecated Qt constructions.
      Mark arguments as unused, remove unused variables.
      Properly sort constructors
      b1c3af20
  10. 21 May, 2020 1 commit
    • Jan Blackquill's avatar
      Add users KCM · b1c941fc
      Jan Blackquill authored
      Summary:
      This patch introduces a new users KCM based off of the AccountsService.
      Co-authored-by: Nicolas Fella's avatarNicolas Fella <nicolas.fella@gmx.de>
      
      Closes T7246
      
      Test Plan:
      {F8185451}
      {F8185453}
      {F8185454}
      
      Reviewers: #plasma, #vdg, ngraham
      
      Reviewed By: #vdg, ngraham
      
      Subscribers: ltoscano, mart, yurchor, iasensio, meven, crossi, The-Feren-OS-Dev, davidedmundson, broulik, filipf, ngraham, nicolasfella, zzag, plasma-devel
      
      Tags: #plasma
      
      Maniphest Tasks: T7246
      
      Differential Revision: https://phabricator.kde.org/D28154
      b1c941fc