Author: locilka Date: Tue Aug 28 16:20:52 2007 New Revision: 40546 URL: http://svn.opensuse.org/viewcvs/yast?rev=40546&view=rev Log: - Fixed restoration in autoyast (#199657). - 2.15.3 Modified: trunk/restore/VERSION trunk/restore/package/yast2-restore.changes trunk/restore/src/restore_auto.ycp Modified: trunk/restore/VERSION URL: http://svn.opensuse.org/viewcvs/yast/trunk/restore/VERSION?rev=40546&r1=... ============================================================================== --- trunk/restore/VERSION (original) +++ trunk/restore/VERSION Tue Aug 28 16:20:52 2007 @@ -1 +1 @@ -2.15.2 +2.15.3 Modified: trunk/restore/package/yast2-restore.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/restore/package/yast2-restore.cha... ============================================================================== --- trunk/restore/package/yast2-restore.changes (original) +++ trunk/restore/package/yast2-restore.changes Tue Aug 28 16:20:52 2007 @@ -1,4 +1,10 @@ ------------------------------------------------------------------- +Tue Aug 28 16:07:23 CEST 2007 - locilka@suse.cz + +- Fixed restoration in autoyast (#199657). +- 2.15.3 + +------------------------------------------------------------------- Mon Jul 30 17:48:21 CEST 2007 - locilka@suse.cz - 2.15.2 Modified: trunk/restore/src/restore_auto.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/restore/src/restore_auto.ycp?rev=... ============================================================================== --- trunk/restore/src/restore_auto.ycp (original) +++ trunk/restore/src/restore_auto.ycp Tue Aug 28 16:20:52 2007 @@ -19,6 +19,9 @@ import "Popup"; import "Restore"; import "Wizard"; +import "Directory"; +import "FileUtils"; + include "restore/ui.ycp"; /* The main () */ @@ -29,6 +32,7 @@ string func = ""; map param = $[]; +string filename = sformat ("%1/restore_archives_tmpfile.ycp", Directory::tmpdir); /* Check arguments */ if (size(WFM::Args()) > 0 && is(WFM::Args(0), string)) @@ -48,6 +52,13 @@ if (func == "Import") { ret = Restore::Import(param); + + if (FileUtils::Exists (filename)) { + SCR::Execute (.target.remove, filename); + } + + // bugzilla #199657 + SCR::Write (.target.ycp, filename, param["archives"]:[]); } /* create a summary */ else if (func == "Summary") @@ -77,7 +88,18 @@ import "Progress"; // Read archive file - list<string> volumes = param["archives"]:[]; + list <string> volumes = []; + + // bugzilla #199657 + if (param["archives"]:[] != []) { + y2milestone ("Some volumes set"); + volumes = param["archives"]:[]; + } else if (FileUtils::Exists (filename)) { + y2milestone ("Reading volumes from tmpfile"); + volumes = (list <string>) SCR::Read (.target.ycp, filename); + } + + y2milestone ("Volumes: %1", volumes); if (size(volumes) == 0) { @@ -91,6 +113,8 @@ integer index = 0; foreach(string volume, volumes, ``{ + y2milestone ("Scanning volume %1", volume); + if (ui == `abort) { ret = false; @@ -106,6 +130,7 @@ map read_result = Restore::ReadNextVolume(volume); read = (boolean)(read_result["success"]:false); } + y2milestone ("Reading volume %1 returned %2", volume, read); if (read == false) { -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org