fixed seg fault on dd