jlaurens / synctex

Synchronization for TeX
MIT License
57 stars 19 forks source link

Bug in post scriptum parser y_offset #50

Open tsc25 opened 1 year ago

tsc25 commented 1 year ago

Line 4564 of synctex_parser.c (towards end of _synctex_scan_post_scriptum function) should read:

    scanner->y_offset = fs.value;

instead of x_offset.

Because scanner->y_offset and scanner->y_offset are initialised to the bogus value 6.027e23, setting any X or Y offset in the post scriptum leads to synctex applying a y_offset of 6.027e23. So this bug breaks the post scriptum offset override feature, leading to bogus output from synctex view/edit if any offset is set.