diff options
author | Chris Lumens <clumens@redhat.com> | 2010-08-31 14:32:38 -0400 |
---|---|---|
committer | Chris Lumens <clumens@redhat.com> | 2010-10-15 16:42:26 -0400 |
commit | 1d9d84658e80b7882ac77d5479cc598fe8592fc4 (patch) | |
tree | 13e9a1fd941c46a76571a12cf85416d05650ab30 /loader/method.c | |
parent | 5c04375756b53165ba961fa544effd73c56584f9 (diff) | |
download | anaconda-1d9d84658e80b7882ac77d5479cc598fe8592fc4.tar.gz anaconda-1d9d84658e80b7882ac77d5479cc598fe8592fc4.tar.xz anaconda-1d9d84658e80b7882ac77d5479cc598fe8592fc4.zip |
Remove the unused mountNfsImage and all code that was only called by it.
Diffstat (limited to 'loader/method.c')
-rw-r--r-- | loader/method.c | 71 |
1 files changed, 0 insertions, 71 deletions
diff --git a/loader/method.c b/loader/method.c index 5e1b4da5d..273649b94 100644 --- a/loader/method.c +++ b/loader/method.c @@ -59,15 +59,6 @@ /* boot flags */ extern uint64_t flags; -static void stripTrailingSlash(char *path) { - size_t len = strlen(path); - - if (len == 0) - return; - if (path[len-1] == '/') - path[len-1] = '\0'; -} - /* returns the *absolute* path (malloced) to the #1 iso image */ /* get timestamp and description of ISO image from stamp file */ /* returns 0 on success, -1 otherwise */ @@ -444,65 +435,3 @@ int getFileFromBlockDevice(char *device, char *path, char * dest) { unlink("/tmp/mnt"); return rc; } - -void setStage2LocFromCmdline(char * arg, struct loaderData_s * ld) { - logMessage(INFO, "Setting stage2 from %s", arg); - - if (!strncmp(arg, "nfs:", 4)) { - ld->method = METHOD_NFS; - ld->stage2Data = calloc(sizeof(struct nfsInstallData), 1); - - parseNfsHostPathOpts(arg + 4, - &(((struct nfsInstallData *)ld->stage2Data)->host), - &(((struct nfsInstallData *)ld->stage2Data)->directory), - &(((struct nfsInstallData *)ld->stage2Data)->mountOpts)); - stripTrailingSlash(((struct nfsInstallData *)ld->stage2Data)->directory); - - logMessage(INFO, "method nfs - %s | %s | %s", - (((struct nfsInstallData *)ld->stage2Data)->host), - (((struct nfsInstallData *)ld->stage2Data)->directory), - (((struct nfsInstallData *)ld->stage2Data)->mountOpts) - ); - } else if (!strncmp(arg, "nfsiso:", 7)) { - ld->method = METHOD_NFS; - ld->stage2Data = calloc(sizeof(struct nfsInstallData), 1); - - parseNfsHostPathOpts(arg + 7, - &(((struct nfsInstallData *)ld->stage2Data)->host), - &(((struct nfsInstallData *)ld->stage2Data)->directory), - &(((struct nfsInstallData *)ld->stage2Data)->mountOpts)); - - logMessage(INFO, "method nfsiso - %s | %s | %s", - (((struct nfsInstallData *)ld->stage2Data)->host), - (((struct nfsInstallData *)ld->stage2Data)->directory), - (((struct nfsInstallData *)ld->stage2Data)->mountOpts) - ); - } else if (!strncmp(arg, "cdrom:", 6)) { - ld->method = METHOD_CDROM; - - logMessage(INFO, "method cdrom"); - } else if (!strncmp(arg, "harddrive:", 10) || - !strncmp(arg, "hd:", 3)) { - size_t offset; - - arg += strcspn(arg, ":"); - if (!*arg || !*(arg+1)) - return; - arg += 1; - offset = strcspn(arg, ":"); - - ld->method = METHOD_HD; - ld->stage2Data = calloc(sizeof(struct hdInstallData), 1); - ((struct hdInstallData *)ld->stage2Data)->partition = strndup(arg, offset); - arg += offset; - if (*arg && *(arg+1)) - ((struct hdInstallData *)ld->stage2Data)->directory = strdup(arg+1); - else - ((struct hdInstallData *)ld->stage2Data)->directory = NULL; - - logMessage(INFO, "method hd - %s | %s", - ((struct hdInstallData *)ld->stage2Data)->partition, - ((struct hdInstallData *)ld->stage2Data)->directory - ); - } -} |