This diff improves error-handling in LibarchivePlugin::list(). Previously we only checked whether we could read until the end of the archive, and even if we couldn't there was no error shown to the user. The diff checks the return value of both archive_read_next_header() and archive_read_data_skip(), and shows a corrupt archive query if either was not successful.
This partially solves bug 411074, as Ark now at least gives a warning when opening the archive. We still need to improve error-handling when extracting, but the code in LibarchivePlugin::extractFiles() is such a mess currently so it's a larger task.