Author: pebender
Date: Sun Nov 16 11:10:35 2008
New Revision: 3965

Modified:
    trunk/gar-minimyth/html/minimyth/document-changelog.txt
     
trunk/gar-minimyth/script/meta/minimyth/files/source/rootfs/etc/rc.d/rc.pl

Log:
- Fixed bug that caused perl init scripts to create '/STDOUT' rather than
   '/var/log/minimyth.log'.



Modified: trunk/gar-minimyth/html/minimyth/document-changelog.txt
==============================================================================
--- trunk/gar-minimyth/html/minimyth/document-changelog.txt     (original)
+++ trunk/gar-minimyth/html/minimyth/document-changelog.txt     Sun Nov 16  
11:10:35 2008
@@ -18,6 +18,8 @@
        appears that there is at least one bug in Sys::Hostname::hostname  
that
        causes the value to be incorrect when the host name is changed after
        Sys::Hostname is loaded.
+    - Fixed bug that caused perl init scripts to create '/STDOUT' rather  
than
+      '/var/log/minimyth.log'.

  Updated packages
      Updated gtk/cairo.

Modified:  
trunk/gar-minimyth/script/meta/minimyth/files/source/rootfs/etc/rc.d/rc.pl
==============================================================================
---  
trunk/gar-minimyth/script/meta/minimyth/files/source/rootfs/etc/rc.d/rc.pl      
 
(original)
+++  
trunk/gar-minimyth/script/meta/minimyth/files/source/rootfs/etc/rc.d/rc.pl      
 
Sun Nov 16 11:10:35 2008
@@ -93,31 +93,26 @@

      $minimyth->var_load();

-    # Redirect stderr and stdout to either /dev/null or  
/var/log/minimyth.log,
-    # depending on the value of MM_DEBUG.
-    my $log_file = File::Spec->devnull;
-    if ((defined($minimyth->var_get('MM_DEBUG'))) &&  
($minimyth->var_get('MM_DEBUG') eq 'yes'))
+    # Redirect stderr and stdout to /var/log/minimyth.log,
+    my $log_file = '/var/log/minimyth.log';
+    if (! -e $log_file)
      {
-        $log_file = '/var/log/minimyth.log';
-        if (! -e $log_file)
+        my $log_dir = File::Basename::dirname($log_file);
+        if (! -e $log_dir)
          {
-            my $log_dir = File::Basename::dirname($log_file);
-            if (! -e $log_dir)
-            {
-                File::Path::mkpath($log_dir);
-            }
-            if (-w $log_dir)
-            {
-                open(FILE, '>', $log_file);
-                chmod(0666, $log_file);
-                close(FILE);
-            }
+            File::Path::mkpath($log_dir);
+        }
+        if (-w $log_dir)
+        {
+            open(FILE, '>', $log_file);
+            chmod(0666, $log_file);
+            close(FILE);
          }
      }
-    open(STDERR, '>', 'STDOUT');
      if (-e $log_file)
      {
          open(STDOUT, '>>', $log_file);
+        open(STDERR, '>&', 'STDOUT');
      }

      my $dir = Cwd::abs_path(File::Basename::dirname(__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