1. 02 May, 2020 2 commits
  2. 27 Apr, 2020 3 commits
  3. 26 Apr, 2020 1 commit
    • Friedrich W. H. Kossebau's avatar
      API dox: improve docs for Q_DECLARE_FLAGS-based flags · de30ea00
      Friedrich W. H. Kossebau authored
      KApiDox & ECMAddQch have been just teached about Q_DECLARE_FLAGS, so the
      underlying typedefs are no longer skipped by doxygen, but can be
      documented now, allowing links to be generated for these types e.g. when
      used as arguments.
      The "#" prefix to the enum name in the description text of all the
      Q_DECLARE_FLAGS docs seems needed to properly trigger doxygen autolinks.
      Wording of pre-existing docs for those flags has been adapted to
      pattern used elsewhere in KF.
  4. 21 Apr, 2020 1 commit
    • Stefan Brüns's avatar
      [FstabWatcher] Fix loosing of fstab watcher · 5f975738
      Stefan Brüns authored
      In case the fstab is deleted (caused by editing it), the watch will be
      removed. The code already partially dealed with this, i.e. it tried to
      readd the watch, but did not check if the operation succeeded and dropped
      any further changes if not.
      Keep a watch on the containing folder and readd the fstab on change
      events. Unfortunately QFilesystemWatcher does not allow fine granular
      change events, though as /etc/ is likely mostly silent this should not
      matter much.
      The bug becomes apparent when e.g. editing the fstab with VIM, which
      has a quite broken implementation of creating temporary/backup files
      during save: it moves away the original file and creates the new file
      directly under the original name, instead of using a atomic rename.
      Test Plan:
      1. solid-hardware listen
      2. open fstab with vi, save a few times
      Without the change, solid will loose the watch sooner or later.
      Depends on D28779
      Reviewers: #frameworks, ngraham, apol
      Reviewed By: ngraham, apol
      Subscribers: apol, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28780
  5. 13 Apr, 2020 3 commits
    • Stefan Brüns's avatar
      [Fstab] Do not emit deviceAdded twice on fstab/mtab changes · 3adf5d47
      Stefan Brüns authored
      The deviceAdded signal was emitted twice, once with the old device list
      in m_deviceList, once with the new one.
      The first one is actually wrong and was fixed in kdelibs4 by moving the
      deviceAdded signal after the m_deviceList update. In KF5, the second
      signal was added but the first one never removed.
      Move the m_deviceList update to the top (though for deviceRemoved it
      does not matter much), and remove the second signal.
      Depends on D28779
      Test Plan:
      1. solid-hardware listen
      2. add an entry to the fstab
      -> deviceAdded is only emitted once
      Reviewers: #frameworks, afiestas, apol
      Reviewed By: apol
      Subscribers: apol, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28782
    • Stefan Brüns's avatar
      [Fstab] Use new style connect API · 62de2826
      Stefan Brüns authored
      Depends on D28778
      Test Plan: No functional changes
      Reviewers: #frameworks, apol
      Reviewed By: apol
      Subscribers: kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28779
    • Stefan Brüns's avatar
      [FstabWatcher] Use static QStringLiteral instead of macro · 340e1ac7
      Stefan Brüns authored
      QFilesystemWatcher::addPath takes a QString as argument, so avoid
      construction of tempary QString on each call.
      This also avoids a name clash between the Solid::Backends::Fstab::FSTAB
      logging category and the FSTAB macro.
      Test Plan: no functional changes
      Reviewers: #frameworks, apol
      Reviewed By: apol
      Subscribers: broulik, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28778
  6. 11 Apr, 2020 1 commit
  7. 04 Apr, 2020 1 commit
  8. 02 Apr, 2020 1 commit
    • Stefan Brüns's avatar
      [Fstab] Ensure uniqueness for all filesystem types · e468daf0
      Stefan Brüns authored
      Commit a99c6136 ("Samba: Ensure to differenciate mounts sharing the
      same source") only fixed the multiple mount problem for SMB share. This
      can also happen for all other mounts (remounted local file systems,
      NFS, ...).
      Also clarify the comment.
      Reviewers: #frameworks, meven, broulik, sitter
      Reviewed By: meven, broulik, sitter
      Subscribers: broulik, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28488
  9. 01 Apr, 2020 1 commit
    • Méven Car's avatar
      Samba: Ensure to differenciate mounts sharing the same source · a99c6136
      Méven Car authored
      `getmntent` for samba returns fsname of the form "//server/folder" (same as `mount`)
      It is not sufficient to use in udi as device name as it does not differenciate mounts sharing the same source but having different mount points.
      BUG: 418906
      FIXED-IN: 5.69
      Test Plan:
      With a local cifs mount point:
      $ solid-hardware5 list | grep ourfiles
      udi = '/org/kde/fstab///meven-synapse/ourfiles'
      $ solid-hardware5 list | grep ourfiles
      udi = '/org/kde/fstab///meven-synapse/ourfiles:/media/samba'
      Reviewers: #frameworks, sitter
      Reviewed By: sitter
      Subscribers: ahmadsamir, anthonyfieroni, sitter, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D28476
  10. 22 Mar, 2020 1 commit
  11. 12 Mar, 2020 1 commit
  12. 10 Mar, 2020 1 commit
    • Harald Sitter's avatar
      hardware tool: define syntax via syntax arg · 8dfb727d
      Harald Sitter authored
      This way the commands syntax is always immediately visible
      in the help text.
      Help that doesn't help, and
      previously the help would essentially just end up telling you to
      run --commands to actually get help -.-
      The existing syntax argument of addPositionArgument will simply
      print the syntax help undearneath the usage line, thus giving
      immediate access to information on how to use the application
      without first having to go through the --commands argument
      (--commands still exists for backwards compat)
      Test Plan: -h now useful
      Subscribers: broulik, bruns, kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D26841
  13. 07 Mar, 2020 2 commits
  14. 06 Mar, 2020 1 commit
  15. 03 Mar, 2020 1 commit
  16. 17 Feb, 2020 1 commit
    • Milian Wolff's avatar
      Fix inverted logic in IOKitStorage::isRemovable · d2172d3c
      Milian Wolff authored
      Reading through the code, I realized that the isRemovable check
      returned true when the kDADiskDescriptionDeviceInternalKey property
      is set to true. But that sounds like the check needs to be inverted:
      According to [1] e.g. a disk is non-removable when it is internal.
      And kDADiskDescriptionDeviceInternalKey returns whether the disk
      is internal, not external.
      [1]: https://stackoverflow.com/questions/38499860/thunderbolt-drives-not-marked-as-ejectable-in-disk-arbitration-iokit-although-th#comment64407405_38499860
      Output from `solid-hardware5 details` and `... nonportableinfo`
      on a MacBook Pro Retina, 13-inch, Mid 2014 with macOS 10.15.2,
      before this patch:
      udi = 'IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/RP06@1C,5/IOPP/SSD0@0/AppleAHCI/PRT0@0/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDriver/APPLE SSD SM0256F Media'
        parent = 'IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/RP06@1C,5/IOPP/SSD0@0/AppleAHCI/PRT0@0/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDriver'  (string)
        vendor = ''  (string)
        product = 'APPLE SSD SM0256F                       '  (string)
        description = 'APPLE SSD SM0256F Media'  (string)
        icon = 'drive-removable-media'  (string)
        Block.major = 1  (0x1)  (int)
        Block.minor = 0  (0x0)  (int)
        Block.device = '/dev/disk0'  (string)
        StorageAccess.accessible = false  (bool)
        StorageAccess.filePath = ''  (string)
        StorageAccess.ignored = false  (bool)
        StorageDrive.bus = 'Platform'  (0x5)  (enum)
        StorageDrive.driveType = 'HardDisk'  (0x0)  (enum)
        StorageDrive.removable = true  (bool)
        StorageDrive.hotpluggable = false  (bool)
        StorageDrive.inUse = true  (bool)
        StorageDrive.size = 251000193024  (0x3a70c70000)  (qulonglong)
        StorageVolume.ignored = false  (bool)
        StorageVolume.usage = 'PartitionTable'  (0x3)  (enum)
        StorageVolume.fsType = ''  (string)
        StorageVolume.label = ''  (string)
        StorageVolume.uuid = ''  (string)
        StorageVolume.size = 251000193024  (0x3a70c70000)  (qulonglong)
      udi = 'IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/RP06@1C,5/IOPP/SSD0@0/AppleAHCI/PRT0@0/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDriver/APPLE SSD SM0256F Media'
        BSD Major = 1  (0x1)  (int)
        BSD Minor = 0  (0x0)  (int)
        BSD Name = 'disk0'  (string)
        BSD Unit = 0  (0x0)  (int)
        Content = 'GUID_partition_scheme'  (string)
        Content Hint = ''  (string)
        Ejectable = false  (bool)
        IOBusyInterest = 'IOCommand is not serializable'  (string)
        IOGeneralInterest = 'IOCommand is not serializable'  (string)
        IOMediaIcon = ''  (string)
        IOPolledInterfaceStack = 'IOPolledFilePollers is not serializable'  (string)
        Leaf = false  (bool)
        Open = true  (bool)
        Preferred Block Size = 512  (0x200)  (qlonglong)
        Removable = false  (bool)
        Size = 251000193024  (0x3a70c70000)  (qlonglong)
        Whole = true  (bool)
        Writable = true  (bool)
        className = 'IOMedia'  (string)
      Note the `Ejectable = false  (bool)` vs.
      `StorageDrive.removable = true  (bool)`. The patch here fixes
      it to yield `StorageDrive.removable = false  (bool)`
      Subscribers: kde-frameworks-devel
      Tags: #frameworks
      Differential Revision: https://phabricator.kde.org/D27065
  17. 12 Feb, 2020 2 commits
  18. 09 Feb, 2020 1 commit
  19. 01 Feb, 2020 1 commit
  20. 30 Jan, 2020 1 commit
  21. 19 Jan, 2020 1 commit
  22. 11 Jan, 2020 1 commit
  23. 10 Jan, 2020 1 commit
  24. 06 Jan, 2020 1 commit
  25. 03 Jan, 2020 1 commit
  26. 30 Dec, 2019 1 commit
  27. 21 Dec, 2019 2 commits
  28. 19 Dec, 2019 2 commits
  29. 16 Dec, 2019 1 commit
  30. 15 Dec, 2019 2 commits