fix bugs that the position is not the file used by getting with [-from parameter]