Core: Allow setMaxLocks to be called with 0, add getMaxLocks