Reset pointers first