ArrayIndexOutOfBoundsException while using gotoFrame() method

Fix issue with gotoFrame method. If frameNo is greater than index of last IDR sample (sync sample) in video track, method throws ArrayIndexOutOfBoundsException.
Proposed code guarantees that syncSamples array is never going to be read out of bounds.