Minor fixes, including e.g. fix when creating children