1. 23 Nov, 2021 1 commit
  2. 20 Nov, 2021 1 commit
    • Alexander Lohnau's avatar
      Allow loading of Thumbnailers using embedded json metadata · fc086a65
      Alexander Lohnau authored
      This way thumbnailer plugins don't need to be loaded using the KServiceTypeTrader
      mechanism, but can use embedded json metadata.
      KServiceTypeTrader is planned to go away in KF6.
      This also simplifies the code once the KServiceTypeTrader code path is dropped, because
      we can then load the metadata from the binary path and don't have to use
      KServiceTypeTrader to get the desktop file for the given binary.
      By using KPluginInfo to convert the metadata to json on the fly, we don't need to
      do another query for the file on disk and then a reparsing of the desktop file.
      This is ~2.5 times slower and even requires a few more lines to implement.
      Counterpart of frameworks/kio!630
      Task: https://phabricator.kde.org/T12179
  3. 09 Nov, 2021 1 commit
  4. 08 Nov, 2021 1 commit
  5. 03 Nov, 2021 1 commit
  6. 22 Oct, 2021 1 commit
  7. 20 Oct, 2021 1 commit
  8. 19 Oct, 2021 2 commits
  9. 16 Oct, 2021 1 commit
    • Ahmad Samir's avatar
      kio_filenamesearch: fix crash due to KCoreDirLister changes · c3d52ebe
      Ahmad Samir authored
      Error reporting was changed in KCoreDirlister, to match the original behaviour
      we need to explicitly disable auto error handling.
      This fixes a crash while searching in Dolphin, kio_filenamesearch intrenally
      uses a dirlister, and a nested event loop, if there is an error while listing
      some dir it tries to report it using a job ui delegate, but the parent job
      could well be dead by that time, which causes a crash:
      "QWidget: Cannot create a QWidget without QApplication"
      Note that this crash only happens if KDE_FORK_SLAVES is _not_ set.
      BUG: 438187
      FIXED-IN: 21.08.3
      (cherry picked from commit 5dff395e)
  10. 14 Oct, 2021 2 commits
    • Harald Sitter's avatar
      SCM_SILENT typo-- · ad7efecf
      Harald Sitter authored
    • Harald Sitter's avatar
      sftp: merge the two uds creation paths · 0cf6aaa6
      Harald Sitter authored
      this was previously wildly duplicated. createUDSEntry has been refitted
      to support both calls from stat() and from listDir().
      createUDSEntry now takes an incoming SFTPAttributesPtr (taking ownership
      of the attribute) and fills the udsentry accordingly. for listDir
      efficiency's sake we pass in the entry by reference as well as the
      details such that we can avoid needless work where possible.
      the function now returns a conclusive Result, callers may naturally
      ignore it.
      listDir no longer aborts on readlink errors. indeed any errors coming
      out of udsentry creation shouldn't impact listing. just because a file
      fails to list doesn't mean the entire listing should stop 🤷
      listDir now ignores readlink problems. there's no reason why failing to
      read links would abort the dir listing
  11. 08 Oct, 2021 11 commits
    • Harald Sitter's avatar
      sftp: use auto when the type is obvious · 2cda5518
      Harald Sitter authored
    • Harald Sitter's avatar
      sftp: sort includes · d9200b8e
      Harald Sitter authored
    • Harald Sitter's avatar
      SCM_SILENT typo-- · 4e95136d
      Harald Sitter authored
    • Harald Sitter's avatar
      sftp: don't declare multiple vars in the same line · 6134b87b
      Harald Sitter authored
      it's poor form and gets in the way of readability
    • Harald Sitter's avatar
      sftp: scope variables more tightly · 92babb9b
      Harald Sitter authored
    • Harald Sitter's avatar
      sftp: stop calling closeConnection a million times · 549c05cf
      Harald Sitter authored
      divide openConnection in the wrapper function openConnect and the
      internal openConnectionWithoutCloseOnError. the former calls the latter
      and automatically calls closeConnection if an error was returned. the
      internal function no longer calls closeConnection at all
      also cleaned up style oddities while stepping through the code (fewer
      line breaking, fewer useless var assignment, no longer `else if` after
    • Harald Sitter's avatar
      sftp: start splitting apart openconnectoin · 423625d0
      Harald Sitter authored
      it's way too large, way too complicated, way to repetitively concerned
      with cleanup. fingerprinting is a fairly isolated bit, so split it into
      a helper function. this also helps reduce the in-scope variables and in
      turn makes it less likely that we forget to clean up something
      also use scopeguards for cleanup in the new function. also to reduce
      repetition and ensure cleanup
    • Harald Sitter's avatar
      sftp: deduplicate mimetype sending · dab6ef10
      Harald Sitter authored
      no sense having that both in the open and the get functions. move it to
      a helper function.
      now also uses std::array instead of raw char[] to look more modern
    • Harald Sitter's avatar
      sftp: bump libssh requirement to at least 0.8.3 · fd9bd198
      Harald Sitter authored
      even that is very generous. it's 0.8.3 has been out for more than 3
    • Harald Sitter's avatar
      completely rejigger the way resuming works on smb · fba3079e
      Harald Sitter authored
      the resuming logic is super duplicating and was also somewhat
      divergent between the duplicates.
      to resolve this there's now a new unified couple of helpers that
      specifically deal with establishing context on a file transfer. this
      actually maybe should eventually move to KIO proper. it seems to me that
      every implementation needs to do more or less the same thing except for
      the IO specifics
      - shouldResume is called relatively early on and establishes the
      context. the context is entirely dependent on the resume configuration
      at hand. if KIO::Resume is set we resume in-place, otherwise we may have
      an intermediate .part file. if neither is applicable then we straight up
      need to overwrite. this effectively hides the details of the
      intermediate url switch. the actual transfer logic in smb_dir gets a
      context back with the destination configured to where it should write to
      (not necessarily where the file will end up at in the end)
      - concludeResumeHasError is call...
    • Méven Car's avatar
      sftp: avoid bogus KIO::UDSEntry::UDS_CREATION_TIME values · 0cbdeb1f
      Méven Car authored
      "flags & SSH_FILEXFER_ATTR_CREATETIME" check was missing in listDir
      CCBUG: 375305
  12. 07 Oct, 2021 1 commit
  13. 04 Oct, 2021 2 commits
  14. 02 Oct, 2021 2 commits
  15. 30 Sep, 2021 5 commits
    • Harald Sitter's avatar
      fix the dep5 file · 2fa7899d
      Harald Sitter authored
      it should annotate this source, not the source within the source
    • Harald Sitter's avatar
      apply mtime on smb->smb copies · 17de407c
      Harald Sitter authored
      previously this behaved wildly inconsistently with the other copy
      functions and other workers. copying on the same protocol doesn't really
      change anything, if anything it  is even more expected to not disturb
      the mtime, certainly when we were provided with a modify time, which all
      this is contingent on anyway
    • Harald Sitter's avatar
      stop mtime duplication · 1b464d30
      Harald Sitter authored
      applying the mtime was duplicated across multiple functions when indeed
      it is largely the same code with only the actual setting being slightly
      variable. use a template function with callback instead to share the
      sharable bits.
      also, since smbc_utime is used in two functions move that to its own
      helper built on top to remove even the callback duplication
    • Harald Sitter's avatar
      log more flags · 82cf40ac
      Harald Sitter authored
      they can change behavior quite a bit
    • Harald Sitter's avatar
      use posix mode macros · e5c2f63e
      Harald Sitter authored
      ...to be more consistent with the rest of the code
  16. 25 Sep, 2021 1 commit
  17. 23 Sep, 2021 1 commit
  18. 22 Sep, 2021 1 commit
    • Harald Sitter's avatar
      implement timeouts from ws-discovery · bef55f10
      Harald Sitter authored
      previously we had a global timeout in smb_browse but that was eventually
      removed to not break SMBC discovery, which is also used for listing
      directories. this left WSD without any timeout system when no WSD hosts
      are on the network because the internal timeout tracking would only
      start after the first response.
      instead implement the actually specified timeout mechanics of WSD.
      - /Probe may only be Matched within MATCH_TIMEOUT (m_probeMatchTimer =
      global timeout tracker now)
      - /Resolve may only be Matched within MATCH_TIMEOUT (encapsulated inside
      new WSDResolver)
      - PBSD may only be answered within HTTP_TIMEOUT (couldn't find a
      specified timeout so I'm guessing one would ordinarily use a default
      http timeout, since we only do a single cheap query I'm using a more
      opinionate timeout though)
      MATCH_TIMEOUT is derived form the DPWS spec rather than the underlying
      ws-discovery because it has more lenient timing and is generally a bit
      more assertive with requirements.
      BUG: 436574
  19. 21 Sep, 2021 1 commit
  20. 20 Sep, 2021 2 commits
  21. 19 Sep, 2021 1 commit