add seek by pos function