diff options
author | Jeremy Katz <katzj@redhat.com> | 2002-06-04 16:36:25 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2002-06-04 16:36:25 +0000 |
commit | f13d37314c81388d0d34e7d5a4ec7c05e9b7f578 (patch) | |
tree | aa5126851eb729c784e44a558de55e82cf29c003 /loader/loader.c | |
parent | 002c3b127ec3a2413a6739c6c0872aed954fa663 (diff) | |
download | anaconda-f13d37314c81388d0d34e7d5a4ec7c05e9b7f578.tar.gz anaconda-f13d37314c81388d0d34e7d5a4ec7c05e9b7f578.tar.xz anaconda-f13d37314c81388d0d34e7d5a4ec7c05e9b7f578.zip |
hopefully fixes the loopback mounted iso ftp/http installs for kickstart (#65811)
Diffstat (limited to 'loader/loader.c')
-rw-r--r-- | loader/loader.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/loader/loader.c b/loader/loader.c index 97185b728..430ec0cf6 100644 --- a/loader/loader.c +++ b/loader/loader.c @@ -2302,6 +2302,7 @@ static char * setupKickstart(char * location, struct knownDevices * kd, return NULL; } else if (ksType == KS_CMD_URL) { + char * finalPrefix; memset(&ui, 0, sizeof(ui)); imageUrl = strdup(url); @@ -2350,6 +2351,19 @@ static char * setupKickstart(char * location, struct knownDevices * kd, logMessage("failed to retrieve second stage"); return NULL; } + + /* now that we've loaded images, the url could have changed to handle + the multi-disc loopback stuff */ + if (!strcmp(ui.prefix, "/")) + finalPrefix = "/."; + else + finalPrefix = ui.prefix; + + url = malloc(strlen(finalPrefix) + 25 + strlen(ui.address) + strlen(ui.login)); + sprintf(url, "%s://%s%s/%s", + ui.protocol == URL_METHOD_FTP ? "ftp" : "http", + ui.login, ui.address, finalPrefix); + } #endif |