ENOEMPTY return code may be a valid return code from i.e. smbc_rmdir(). The current error reporting code lets such an error code fall through to the default report case, leading to confusing information reported back to the user. This patch adds such a case branch.
Details
Details
Diff Detail
Diff Detail
- Repository
- R320 KIO Extras
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Comment Actions
kio_file returns KIO::ERR_CANNOT_RMDIR when trying to delete a non-empty directory, maybe kio_smb could do the same? Although I see that the above isn't dependent on the command being executed.... But well, is there any other operation that would return ENOTEMPTY? If not, then ERR_CANNOT_RMDIR would be better IMHO (so KIO code or app code can check for it, if needed).
Comment Actions
Well, this (https://api.kde.org/frameworks/kio/html/deprecated.html#_deprecated000015) marks KIO::ERR_COULD_NOT_RMDIR as deprecated. Is there an alternative I should use instead?
Comment Actions
Ah, sorry, apparently there is ERR_CANNOT_RMDIR and ERR_COULD_NOT_RMDIR which translate to the same value with the latter being deprecated. I'll update the patch to use ERR_CANNOT_RMDIR.