Fixed bug in depth for default key bitmask calculations