Kill a segfault
Add an extra config item and clean up some code formatting