segfault on no solution fixed