This is an automated email from the git hooks/post-receive script.

jamessan pushed a commit to branch pu/yaml-excuses
in repository devscripts.

commit efbf1aa93e951de95c7c4ce54e6b89af9fdee954
Author: James McCoy <[email protected]>
Date:   Wed Mar 8 21:07:39 2017 -0500

    grep-excuses: Check for existence of policy-info
    
    This isn't always present (e.g., binNMUs).
    
    Signed-off-by: James McCoy <[email protected]>
---
 scripts/grep-excuses.pl | 25 ++++++++++++++-----------
 1 file changed, 14 insertions(+), 11 deletions(-)

diff --git a/scripts/grep-excuses.pl b/scripts/grep-excuses.pl
index ac75f1a..fbd8eb0 100755
--- a/scripts/grep-excuses.pl
+++ b/scripts/grep-excuses.pl
@@ -325,18 +325,21 @@ for my $source (@{$excuses->{sources}})
        {
            printf("    Maintainer: $source->{maintainer}\n");
        }
-       my %age = %{$source->{policy_info}{age}};
-       if ($age{'current-age'} >= $age{'age-requirement'})
+       if (exists $source->{policy_info})
        {
-           printf("    %d days old (needed %d days)\n",
-               $age{'current-age'},
-               $age{'age-requirement'});
-       }
-       else
-       {
-           printf("    Too young, only %d of %d days old\n",
-               $age{'current-age'},
-               $age{'age-requirement'});
+           my %age = %{$source->{policy_info}{age}};
+           if ($age{'current-age'} >= $age{'age-requirement'})
+           {
+               printf("    %d days old (needed %d days)\n",
+                   $age{'current-age'},
+                   $age{'age-requirement'});
+           }
+           else
+           {
+               printf("    Too young, only %d of %d days old\n",
+                   $age{'current-age'},
+                   $age{'age-requirement'});
+           }
        }
        for my $excuse (@{$source->{excuses}})
        {

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/collab-maint/devscripts.git

_______________________________________________
devscripts-devel mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/devscripts-devel

Reply via email to