webatintel / aquarium

BSD 3-Clause "New" or "Revised" License
24 stars 7 forks source link

Dismiss compilation warning about virtual dtor #131

Closed gyagp closed 4 years ago

gyagp commented 4 years ago

This is to dismiss the warning during compilation as below: warning: delete called on non-final 'RingBufferDawn' that has virtual functions but non-virtual destructor for "delete ringBuffer;" in BufferManagerDawn.cpp(215,13).

hujiajie commented 4 years ago

Thanks, since ~RingBuffer() is a virtual function now, I'd like more refinements here:

  1. Mark ~RingBufferDawn() with override.
  2. The cast right above that delete statement is no longer needed. delete mEqueueBufferList[index]; should be enough.
gyagp commented 4 years ago

Please take another look!

hujiajie commented 4 years ago

LGTM, thanks!