From: Father Chrysostomos Date: Tue, 6 Nov 2012 18:02:21 +0000 (-0800) Subject: svleak.t: Fix a mad failure X-Git-Tag: upstream/5.20.0~4927 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9eb48717912f4fd262be607b74cc3c89014fc58b;p=platform%2Fupstream%2Fperl.git svleak.t: Fix a mad failure --- diff --git a/t/op/svleak.t b/t/op/svleak.t index 96bf092..129bd0a 100644 --- a/t/op/svleak.t +++ b/t/op/svleak.t @@ -33,7 +33,8 @@ sub leak { } # Like leak, but run a string eval instead; takes into account existing -# string eval leaks under -Dmad. The code is used instead of the test name +# string eval leaks under -Dmad (except when -Dmad leaks two or +# more SVs). The code is used instead of the test name # if the name is absent. sub eleak { my ($n,$delta,$code,@rest) = @_; @@ -199,7 +200,8 @@ eleak(2, 0, 'no warnings; nonexistent_function 33838', 'bareword followed by number'); eleak(2, 0, '//dd;'x20, '"too many errors" when parsing m// flags'); eleak(2, 0, 's///dd;'x20, '"too many errors" when parsing s/// flags'); -eleak(2, 0, 'no warnings; 2 2;BEGIN{}', 'BEGIN block after syntax error'); +eleak(2, !!$Config{mad}, 'no warnings; 2 2;BEGIN{}', + 'BEGIN block after syntax error'); { local %INC; # in case Errno is already loaded eleak(2, 0, 'no warnings; 2@!{',