fixed copy constructor and assignment operator