Decreasing the chances of a segfault