wip: trying to fix buffer- error in thread