Correct MD free Memory