summaryrefslogtreecommitdiffstats
path: root/discover/device-handler.c
diff options
context:
space:
mode:
authorSamuel Mendoza-Jonas <sam@mendozajonas.com>2017-12-12 14:05:40 +1100
committerSamuel Mendoza-Jonas <sam@mendozajonas.com>2017-12-12 16:15:59 +1100
commita2d5a3e3cb55fe3583acaae44fabc7c3d7f8df50 (patch)
tree01779205e51f0e2870e6627873ad8158e0b3694d /discover/device-handler.c
parent865097ff2cbb64f4d5b3122ab09e7b1550ecd3dd (diff)
downloadtalos-petitboot-a2d5a3e3cb55fe3583acaae44fabc7c3d7f8df50.zip
talos-petitboot-a2d5a3e3cb55fe3583acaae44fabc7c3d7f8df50.tar.gz
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>
Diffstat (limited to 'discover/device-handler.c')
-rw-r--r--discover/device-handler.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/discover/device-handler.c b/discover/device-handler.c
index 8ad885f..8223015 100644
--- a/discover/device-handler.c
+++ b/discover/device-handler.c
@@ -1356,7 +1356,7 @@ static void process_url_cb(struct load_url_result *result, void *data)
mac = event_get_param(event, "mac");
char *url = talloc_asprintf(event, "file://%s", result->local);
- event_set_param(event, "pxeconffile", url);
+ event_set_param(event, "pxeconffile-local", url);
dev = discover_device_create(handler, mac, event->device);
ctx = device_handler_discover_context_create(handler, dev);
OpenPOWER on IntegriCloud