Bug 253539
Summary: | Network install (using http or ftp) does not work | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Lorenzo Sartoratti <lorenzo.sartoratti> | ||||
Component: | anaconda | Assignee: | David Cantrell <dcantrell> | ||||
Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | 7 | CC: | erik-fedora, petesbbq | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2007-08-22 18:58:39 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Lorenzo Sartoratti
2007-08-20 14:25:05 UTC
Created attachment 161878 [details]
anaconda-11.2.0.66/loader2/nfsinstall.c patch
I modified your patch a bit. I did this: Index: loader2/nfsinstall.c =================================================================== RCS file: /usr/local/CVS/anaconda/loader2/nfsinstall.c,v retrieving revision 1.46 diff -u -p -r1.46 nfsinstall.c --- loader2/nfsinstall.c 6 Aug 2007 21:36:52 -0000 1.46 +++ loader2/nfsinstall.c 22 Aug 2007 18:46:59 -0000 @@ -277,6 +277,7 @@ void setKickstartNfs(struct loaderData_s int getFileFromNfs(char * url, char * dest, struct loaderData_s * loaderData) { char ret[47]; char * host = NULL, *path = NULL, * file = NULL, * opts = NULL; + char * chk = NULL; int failed = 0; struct networkDeviceConfig netCfg; ip_addr_t *tip; @@ -334,7 +335,12 @@ int getFileFromNfs(char * url, char * de file = path; } else { *file++ ='\0'; - host = sdupprintf("%s/%s", host, path); + chk = host; + chk += strlen(host) - 1; + if (*chk == '/' || *path == '/') + host = sdupprintf("%s%s", host, path); + else + host = sdupprintf("%s/%s", host, path); } logMessage(INFO, "file location: nfs://%s/%s", host, file); So only add the slash if host doesn't end with it and path doesn't begin with it. Thanks. |