moved alloc
seems to work now