Bug 1085313 - Refactor the error handler for icc.{set|unlock}CardLock API. r=ejchen,alive,sfoster