Got rid of forking and added threads instead.