FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > ArchLinux > ArchLinux Development

 
 
LinkBack Thread Tools
 
Old 05-28-2010, 08:04 PM
Chris Lumens
 
Default Make sure the product.img directory is mounted before copying (#587696).

copyUpdatesImg and copyProductImg require that their argument be mounted and
accessible before the copy is performed.
---
loader/nfsinstall.c | 25 ++++++++++++++++---------
1 files changed, 16 insertions(+), 9 deletions(-)

diff --git a/loader/nfsinstall.c b/loader/nfsinstall.c
index 660106a..09a2109 100644
--- a/loader/nfsinstall.c
+++ b/loader/nfsinstall.c
@@ -324,15 +324,22 @@ char * mountNfsImage(struct installMethod * method,

free(buf);

- checked_asprintf(&buf, "%s/updates.img", fullPath);
- logMessage(INFO, "Looking for updates in %s", buf);
- copyUpdatesImg(buf);
- free(buf);
-
- checked_asprintf(&buf, "%s/product.img", fullPath);
- logMessage(INFO, "Looking for product in %s", buf);
- copyProductImg(buf);
- free(buf);
+ if (!doPwMount(fullPath, "/tmp/disk-image", "nfs", mountOpts, NULL)) {
+ logMessage(INFO, "Looking for updates in %s/updates.img", fullPath);
+ checked_asprintf(&buf, "/tmp/disk-image/updates.img");
+ copyUpdatesImg(buf);
+ free(buf);
+
+ logMessage(INFO, "Looking for product in %s/product.img", fullPath);
+ checked_asprintf(&buf, "/tmp/disk-image/product.img");
+ copyProductImg(buf);
+ free(buf);
+
+ umount("/tmp/disk-image");
+ unlink("/tmp/disk-image");
+ } else {
+ logMessage(INFO, "Couldn't mount %s for updates and product", fullPath);
+ }

stage = NFS_STAGE_DONE;
break;
--
1.7.0.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 10:08 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org