Fixes compile. Still working on segflt