Making debugging print locate not take forever. Thought I removed that already.
Adding segfault stack traces, cleaning up error reporting to remove extra newlines, and correctly generating the names of bed directories.