[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [OSSTEST PATCH 1/5] flight_otherjob: Use confess rather than die
When this error trips it is usually because the call site looked up an unset runvar and it can be hard to tell what that runvar was. If we use confess we will at least find out the calling line number... Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> --- Osstest.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Osstest.pm b/Osstest.pm index 85a6e78b..92b1a0ea 100644 --- a/Osstest.pm +++ b/Osstest.pm @@ -22,6 +22,7 @@ use warnings; use POSIX; use File::Basename; use IO::File; +use Carp; BEGIN { use Exporter (); @@ -370,7 +371,7 @@ sub flight_otherjob ($$) { my ($thisflight, $otherflightjob) = @_; return $otherflightjob =~ m/^([^.]+)\.([^.]+)$/ ? ($1,$2) : $otherflightjob =~ m/^\.?([^.]+)$/ ? ($thisflight,$1) : - die "$otherflightjob ?"; + confess "$otherflightjob ?"; } sub other_revision_job_suffix ($$) { @@ -444,3 +445,4 @@ sub show_abs_time ($) { } 1; + -- 2.11.0 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |