The World Federation One Stop Fiqh

Ruling 1168

If after the time for ẓuhr and ʿaṣr has expired one knows that he performed a four rakʿah prayer but he does not know whether he performed it with the intention of ẓuhr or ʿaṣr, he must perform another four rakʿah prayer with the intention of making up the prayer that is obligatory on him.