s3: Fix nested get_share_mode_lock calls