Implement forking functionality