- std::for_each(other.data, other.data + NUM_EFFECTS, ref);
- std::for_each(data, data + NUM_EFFECTS, SDL_FreeSurface);
- memcpy(data, other.data, sizeof(Cache));
+ std::for_each(other.data, other.data + CACHE_SIZE, ref);
+ std::for_each(data, data + CACHE_SIZE, SDL_FreeSurface);
+ memcpy(data, other.data, CACHE_SIZE * sizeof(SDL_Surface *));