From: Bill Erickson Date: Mon, 16 Jul 2012 20:56:10 +0000 (-0400) Subject: Squelch uninitialized var warning from hold_copy_targeter X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=c243355bec838c7914129ed12ebea3b6dac80371;p=evergreen%2Fequinox.git Squelch uninitialized var warning from hold_copy_targeter open-ils.storage_stderr.log was getting filled with entries like: "Use of uninitialized value in concatenation (.) or string at /usr/local/share/perl/5.10.1/OpenILS/Application/Storage/Publisher/action.pm" ... consuming disk space endlessly. Stop that! (Stealing Lebbeous' footwork and providing a slightly different solution.) Signed-off-by: Bill Erickson Signed-off-by: Ben Shum Signed-off-by: Dan Scott --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm index e4d7354b80..ddca93e201 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm @@ -1276,7 +1276,7 @@ sub new_hold_copy_targeter { my @good_copies; for my $c (@$all_copies) { # current target - next if ($c->id eq $hold->current_copy); + next if ($hold->current_copy and $c->id eq $hold->current_copy); # circ lib is closed next if ( grep { ''.$_->org_unit eq ''.$c->circ_lib } @closed );