Some stability fixes