]> git.ozlabs.org Git - petitboot/commit
discover/pxe-parser: Fix relative parsing for manual config files
authorSamuel Mendoza-Jonas <sam@mendozajonas.com>
Tue, 12 Dec 2017 03:05:40 +0000 (14:05 +1100)
committerSamuel Mendoza-Jonas <sam@mendozajonas.com>
Tue, 12 Dec 2017 05:15:59 +0000 (16:15 +1100)
commita2d5a3e3cb55fe3583acaae44fabc7c3d7f8df50
tree01779205e51f0e2870e6627873ad8158e0b3694d
parent865097ff2cbb64f4d5b3122ab09e7b1550ecd3dd
discover/pxe-parser: Fix relative parsing for manual config files

Manually specified config files are asynchronously downloaded by
device_handler_process_url() before being parsed. This overwrites the
'pxeconffile' parameter, causing the parser to create relative paths
relative to the downloaded file's path, not the original remote path.

Work around this by setting 'pxeconffile-local' instead to differentiate
between the original config file's location and the local copy.

Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com>
discover/device-handler.c
discover/pxe-parser.c
test/parser/Makefile.am
test/parser/test-pxe-discover-bootfile-async-file.c [new file with mode: 0644]