Fix crash when zypper is locked during pattern inspection

Fixes issue #415.