reset offset_pos on seek to 0

This commit is contained in:
Anthony Minessale 2011-05-17 13:00:34 -05:00
parent 95a18a9e1a
commit e375d1d2f2
1 changed files with 3 additions and 6 deletions

View File

@ -445,15 +445,12 @@ SWITCH_DECLARE(switch_status_t) switch_core_file_seek(switch_file_handle_t *fh,
switch_set_flag(fh, SWITCH_FILE_SEEK);
status = fh->file_interface->file_seek(fh, cur_pos, samples, whence);
if (samples) {
fh->offset_pos = *cur_pos;
fh->offset_pos = *cur_pos;
if (switch_test_flag(fh, SWITCH_FILE_FLAG_WRITE)) {
fh->samples_out = *cur_pos;
}
if (switch_test_flag(fh, SWITCH_FILE_FLAG_WRITE)) {
fh->samples_out = *cur_pos;
}
return status;
}