[Rt-commit] r7714 - in rt/branches/3.7-EXPERIMENTAL: .
ruz at bestpractical.com
ruz at bestpractical.com
Fri Apr 27 20:50:27 EDT 2007
Author: ruz
Date: Fri Apr 27 20:50:25 2007
New Revision: 7714
Modified:
rt/branches/3.7-EXPERIMENTAL/ (props changed)
rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm
Log:
r5171 at cubic-pc: cubic | 2007-04-28 04:50:30 +0400
* $entity->open not always returns true
Modified: rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm (original)
+++ rt/branches/3.7-EXPERIMENTAL/lib/RT/Crypt/GnuPG.pm Fri Apr 27 20:50:25 2007
@@ -522,6 +522,10 @@
# inline PGP block, only in singlepart
unless ( $entity->is_multipart ) {
my $io = $entity->open('r');
+ unless ( $io ) {
+ $RT::Logger->warning( "Entity of type ". $entity->effective_type ." has no body" );
+ return ();
+ }
while ( defined($_ = $io->getline) ) {
next unless /-----BEGIN PGP (SIGNED )?MESSAGE-----/;
my $type = $1? 'signed': 'encrypted';
More information about the Rt-commit
mailing list