OSSP CVS Repository

ossp - Difference in ossp-pkg/cfg/perl/cfg.pm versions 1.5 and 1.6
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [History

ossp-pkg/cfg/perl/cfg.pm 1.5 -> 1.6

--- cfg.pm       2004/11/17 13:15:15     1.5
+++ cfg.pm       2004/11/20 16:51:52     1.6
@@ -241,11 +241,12 @@
     return ($self->{-rc} == $self->CFG_OK ? $arg : undef);
 }
 
-sub node_root ($) {
-    my ($self) = @_;
-    my $node;
-    $self->{-rc} = cfg_node_root($self->{-cfg}, $node);
-    return ($self->{-rc} == $self->CFG_OK ? $node : undef);
+sub node_root ($;$) {
+    my ($self, $node_new) = @_;
+    $node_new ||= \0;
+    my $node_old;
+    $self->{-rc} = cfg_node_root($self->{-cfg}, $node_new, $node_old);
+    return ($self->{-rc} == $self->CFG_OK ? $node_old : undef);
 }
 
 sub node_select ($$$) {

CVSTrac 2.0.1