update offset