template <class ACE_LOCK, class ALLOCATOR> void ACE_Timeprobe_Ex<ACE_LOCK, ALLOCATOR>::increase_size (u_long size) { ACE_GUARD (ACE_LOCK, ace_mon, this->lock_); if (size > this->max_size_) { ACE_timeprobe_t *temp = 0; //FUZZ: disable check_for_lack_ACE_OS ACE_NEW_MALLOC_ARRAY (temp, (ACE_timeprobe_t *) this->allocator ()-> malloc (this->max_size_ * sizeof (ACE_timeprobe_t)), ACE_timeprobe_t, size); //FUZZ: enable check_for_lack_ACE_OS if (this->max_size_ > 0) { ACE_OS::memcpy (temp, this->timeprobes_, this->max_size_ * sizeof (ACE_timeprobe_t)); // Iterates over the array explicitly calling the destructor for // each probe instance, then deallocates the memory ACE_DES_ARRAY_FREE ((ACE_timeprobe_t *)(this->timeprobes_), this->max_size_, this->allocator ()->free, ACE_timeprobe_t); } this->timeprobes_ = temp; this->max_size_ = size; } }
ACE_Timeprobe_Ex<ACE_LOCK, ALLOCATOR>::ACE_Timeprobe_Ex (u_long size) : timeprobes_ (0), lock_ (), max_size_ (size), current_size_ (0), report_buffer_full_ (0), allocator_ (0) { ACE_timeprobe_t *temp; ACE_NEW_MALLOC_ARRAY (temp, (ACE_timeprobe_t *) this->allocator ()-> malloc (this->max_size_*sizeof(ACE_timeprobe_t)), ACE_timeprobe_t, this->max_size_); this->timeprobes_ = temp; }
ACE_Timeprobe_Ex<ACE_LOCK, ALLOCATOR>:: ACE_Timeprobe_Ex (ALLOCATOR *allocator, u_long size) : timeprobes_ (0), lock_ (), max_size_ (size), current_size_ (0), report_buffer_full_ (0), allocator_ (allocator) { ACE_timeprobe_t *temp = 0; //FUZZ: disable check_for_lack_ACE_OS ACE_NEW_MALLOC_ARRAY (temp, (ACE_timeprobe_t *) this->allocator ()-> malloc (this->max_size_*sizeof(ACE_timeprobe_t)), ACE_timeprobe_t, this->max_size_); //FUZZ: enable check_for_lack_ACE_OS this->timeprobes_ = temp; }