Author: pebender
Date: Wed Sep  3 05:59:13 2008
New Revision: 3693

Modified:
    trunk/gar-minimyth/script/perl/perl-MiniMyth/checksums
    trunk/gar-minimyth/script/perl/perl-MiniMyth/files/MiniMyth.pm

Log:
- Changed return value of MimiMyth::url_parse from an array to a hash  
pointer.
- Fixed a few cut and paste errors in MiniMyth::var_* error messages.



Modified: trunk/gar-minimyth/script/perl/perl-MiniMyth/checksums
==============================================================================
--- trunk/gar-minimyth/script/perl/perl-MiniMyth/checksums      (original)
+++ trunk/gar-minimyth/script/perl/perl-MiniMyth/checksums      Wed Sep  3  
05:59:13 2008
@@ -1 +1 @@
-0ffecfbb3f37f00d6ebfa94127a3e112  download/MiniMyth.pm
+496f93cd5248f48ef150cf489f800dcd  download/MiniMyth.pm

Modified: trunk/gar-minimyth/script/perl/perl-MiniMyth/files/MiniMyth.pm
==============================================================================
--- trunk/gar-minimyth/script/perl/perl-MiniMyth/files/MiniMyth.pm       
(original)
+++ trunk/gar-minimyth/script/perl/perl-MiniMyth/files/MiniMyth.pm      Wed Sep 
  
3 05:59:13 2008
@@ -211,7 +211,7 @@
          }
          else
          {
-            $self->message_log('warn', "var_load: file '$conf_file' does  
not exist.");
+            $self->message_log('warn', "MiniMyth::var_load:  
file '$conf_file' does not exist.");
          }
      }
      $shell_command = $shell_command . " ; set";
@@ -272,11 +272,11 @@
      # If the variables have not been loaded and the processed variables  
file exists, then autoload variables.
      (! defined $self->{'conf_variable'}) && (-e '/etc/conf.d/minimyth') &&  
$self->var_load();

-    (defined $self->{'conf_variable'}) || die 'MiniMyth::var_save:  
MiniMyth configuration variables have not been loaded.';
+    (defined $self->{'conf_variable'}) || die 'MiniMyth::var_list:  
MiniMyth configuration variables have not been loaded.';

      my $conf_filter = ($args && $args->{'filter'}) || 'MM_.*';

-    my @list = grep(/^$conf_filter$/, (keys %{$self->{'conf_variable'}}));
+    my @list = sort(grep(/^$conf_filter$/,  
(keys %{$self->{'conf_variable'}})));

      return [EMAIL PROTECTED];
  }
@@ -316,7 +316,7 @@

      (! defined $self->{'conf_variable'}) && (-e '/etc/conf.d/minimyth') &&  
$self->var_load();

-    (defined $self->{'conf_variable'}) || die 'MiniMyth::var_set: MiniMyth  
configuration variables have not been loaded.';
+    (defined $self->{'conf_variable'}) || die 'MiniMyth::var_exists:  
MiniMyth configuration variables have not been loaded.';

      if (defined $self->{'conf_variable'}->{$name})
      {
@@ -985,7 +985,16 @@
          = ($1 || '' , $2   , $3   , $4 || '' , $5   , $6 || '' , $7 || '',  
$8 || '', $9   , $10 || '', $11  , $12 || '')
          if ($url =~  
/^([^:]+):(\/\/(([^:@]*)?(:([EMAIL 
PROTECTED]))?\@)?([^\/]+))?([^?#]*)(\?([^#]*))?(\#(.*))?$/);

-    return ($protocol, $username, $password, $server, $path, $query,  
$fragment);
+    return
+    {
+        'protocol' => $protocol,
+        'username' => $username,
+        'password' => $password,
+        'server'   => $server,
+        'path'     => $path,
+        'query'    => $query,
+        'fragment' => $fragment
+    };
  }

   
#===============================================================================
@@ -998,7 +1007,10 @@
      my $local_file = shift;

      # Parse the URL.
-    my ($remote_protocol, undef, undef, $remote_server, $remote_file,  
undef, undef) = $self->url_parse($url);
+    my $url_parsed      = $self->url_parse($url);
+    my $remote_protocol = $url_parsed->{'protocol'};
+    my $remote_server   = $url_parsed->{'server'};
+    my $remote_file     = $url_parsed->{'path'};

      my $result = '';
      given ($remote_protocol)
@@ -1278,7 +1290,10 @@
      my $local_file = shift;

      # Parse the URL.
-    my ($remote_protocol, undef, undef, $remote_server, $remote_file,  
undef, undef) = $self->url_parse($url);
+    my $url_parsed      = $self->url_parse($url);
+    my $remote_protocol = $url_parsed->{'protocol'};
+    my $remote_server   = $url_parsed->{'server'};
+    my $remote_file     = $url_parsed->{'path'};

      my $result = '';
      given ($remote_protocol)
@@ -1545,7 +1560,13 @@
      }

      # Parse the URL.
-    my ($url_protocol, $url_username, $url_password, $url_server,  
$url_path, $url_options, undef) = $self->url_parse($url);
+    my $url_parsed   = $self->url_parse($url);
+    my $url_protocol = $url_parsed->{'protocol'};
+    my $url_username = $url_parsed->{'username'};
+    my $url_password = $url_parsed->{'password'};
+    my $url_server   = $url_parsed->{'server'};
+    my $url_path     = $url_parsed->{'path'};
+    my $url_options  = $url_parsed->{'options'};

      my $url_file = File::Basename::basename($url_path);
      my $url_ext  = $url_file;

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"minimyth-commits" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/minimyth-commits?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to