[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[OSSTEST PATCH 17/36] target_editfile: Use the same user to retrieve and send



The file "/boot/grub/grub.cfg" on Debian Bookworm isn't accessible
from the "osstest" user, but target_editfile_root() tries to grab the
file as "osstest" then edit it as "root.

Change teditfileex() to use the same $user also to get the file. This
will fix ts-examine-serial-pre step.

Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
---
 Osstest/TestSupport.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Osstest/TestSupport.pm b/Osstest/TestSupport.pm
index 0dded9b2..b86f1d96 100644
--- a/Osstest/TestSupport.pm
+++ b/Osstest/TestSupport.pm
@@ -783,7 +783,7 @@ sub teditfileex {
         logm("editing $rfile to $rdest as $lfile".'{,.new}');
     }
 
-    target_getfile($ho, 60, $rfile, $lfile);
+    tgetfileex($user, $ho, 60, $rfile, $lfile);
     open '::EI', "$lfile" or die "$lfile: $!";
     open '::EO', "> $lfile.new" or die "$lfile.new: $!";
 
-- 
Anthony PERARD




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.