Compiles but gives seg fault.