]> err.no Git - varnish/commitdiff
Minor fix to avoid some potential warnings.
authorknutroy <knutroy@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 24 Aug 2007 13:57:58 +0000 (13:57 +0000)
committerknutroy <knutroy@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 24 Aug 2007 13:57:58 +0000 (13:57 +0000)
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1921 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-tools/regress/lib/Varnish/Test/Client.pm
varnish-tools/regress/lib/Varnish/Test/Server.pm

index 217c8ae5e74eb2ce6a9176edfe889646e575dac0..0245364737150e8f3c538adc4f87bc226102acf2 100644 (file)
@@ -107,7 +107,7 @@ sub shutdown($) {
     if (defined($self->{'fh'})) {
        my $inbuffer = $self->{'mux'}->inbuffer($self->{'fh'});
 
-       if ($inbuffer ne '') {
+       if (defined($inbuffer) and $inbuffer ne '') {
            use Data::Dumper;
 
            $self->log('Discarding: ' . Dumper(\$inbuffer));
index 787478875367798b40b212656d83a12003d0444e..a206468e5e4322fa2e564e4255bf12eb1455db8d 100644 (file)
@@ -147,7 +147,7 @@ sub shutdown($) {
 
     my $inbuffer = $self->{'mux'}->inbuffer($self->{'fh'});
 
-    if ($inbuffer ne '') {
+    if (defined($inbuffer) and $inbuffer ne '') {
        use Data::Dumper;
 
        $self->{'server'}->log('Junk or incomplete request. Discarding: ' . Dumper(\$inbuffer));