another segfault fix