Re: [Xen-devel] [PATCH OSSTEST] Osstest/TestSupport: Hide $ho->{Toolstack} from casual use

2015-09-09 Thread Ian Jackson
Ian Campbell writes ("[PATCH OSSTEST] Osstest/TestSupport: Hide 
$ho->{Toolstack} from casual use"):
> This should only be accessed via toolstack($ho), which is responsible
> for caching the value. Rename the field to _Toolstack to deter code
> from using it.

Acked-by: Ian Jackson 

___
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel


[Xen-devel] [PATCH OSSTEST] Osstest/TestSupport: Hide $ho-{Toolstack} from casual use

2015-07-31 Thread Ian Campbell
This should only be accessed via toolstack($ho), which is responsible
for caching the value. Rename the field to _Toolstack to deter code
from using it.

Signed-off-by: Ian Campbell ian.campb...@citrix.com
---
 Osstest/TestSupport.pm | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/Osstest/TestSupport.pm b/Osstest/TestSupport.pm
index 84e86fd..0370129 100644
--- a/Osstest/TestSupport.pm
+++ b/Osstest/TestSupport.pm
@@ -2076,11 +2076,11 @@ sub guest_vncsnapshot_stash () {
 
 sub toolstack ($) {
 my ($ho) = @_;
-return $ho-{Toolstack} if $ho-{Toolstack};
+return $ho-{_Toolstack} if $ho-{_Toolstack};
 
 my $tsname= $r{toolstack} || 'xend';
-$ho-{Toolstack}= get_host_method_object($ho, 'Toolstack', $tsname);
-return $ho-{Toolstack};
+$ho-{_Toolstack}= get_host_method_object($ho, 'Toolstack', $tsname);
+return $ho-{_Toolstack};
 }
 
 sub authorized_keys () {
-- 
2.1.4


___
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel