]> git.donarmstrong.com Git - debbugs.git/commitdiff
test for equality, and only complain about the conffile missing if debug is set
authorDon Armstrong <don@donarmstrong.com>
Wed, 18 Jan 2012 06:16:06 +0000 (22:16 -0800)
committerDon Armstrong <don@donarmstrong.com>
Wed, 18 Jan 2012 06:16:06 +0000 (22:16 -0800)
Debbugs/Config.pm

index ae4c04fcc4ef6f09d51c967e091dca177ba0656f..f4761a0d3a5f46d16f4b1433f8eaafd363fb7422 100644 (file)
@@ -103,7 +103,7 @@ use Safe;
 # untaint $ENV{DEBBUGS_CONFIG_FILE} if it's owned by us
 # This enables us to test things that are -T.
 if (exists $ENV{DEBBUGS_CONFIG_FILE}) {
-     if (${[stat($ENV{DEBBUGS_CONFIG_FILE})]}[4] = $<) {
+     if (${[stat($ENV{DEBBUGS_CONFIG_FILE})]}[4] == $<) {
          $ENV{DEBBUGS_CONFIG_FILE} =~ /(.+)/;
          $ENV{DEBBUGS_CONFIG_FILE} = $1;
      }
@@ -1025,7 +1025,7 @@ set_default(\%config,'html_expire_note',
 sub read_config{
      my ($conf_file) = @_;
      if (not -e $conf_file) {
-        print STDERR "configuration file '$conf_file' doesn't exist; skipping it";
+        print STDERR "configuration file '$conf_file' doesn't exist; skipping it\n" if $DEBUG;
         return;
      }
      # first, figure out what type of file we're reading in.