Djokovic survives Wawrinka epic to keep Melbourne hat-trick alive