summaryrefslogtreecommitdiff
path: root/fml/lib/FML/Command/DataCheck.pm
diff options
context:
space:
mode:
authorfukachan <fukachan>2006-06-25 11:05:12 +0000
committerfukachan <fukachan>2006-06-25 11:05:12 +0000
commit599890674a7bc271f6861992729106b01b4d8289 (patch)
treee009fea593a5fe36924c325240f04c6fbaeefa7c /fml/lib/FML/Command/DataCheck.pm
parentfa9c29613b6839f673cf1649fe9d03b065021fc6 (diff)
downloadfml8-599890674a7bc271f6861992729106b01b4d8289.tar.gz
fml8-599890674a7bc271f6861992729106b01b4d8289.tar.bz2
fml8-599890674a7bc271f6861992729106b01b4d8289.zip
validate if find_first_plaintext_message() returns object.
Diffstat (limited to 'fml/lib/FML/Command/DataCheck.pm')
-rw-r--r--fml/lib/FML/Command/DataCheck.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/fml/lib/FML/Command/DataCheck.pm b/fml/lib/FML/Command/DataCheck.pm
index 5a746311..8696a7c8 100644
--- a/fml/lib/FML/Command/DataCheck.pm
+++ b/fml/lib/FML/Command/DataCheck.pm
@@ -4,7 +4,7 @@
# All rights reserved. This program is free software; you can
# redistribute it and/or modify it under the same terms as Perl itself.
#
-# $FML: DataCheck.pm,v 1.17 2005/05/27 03:03:34 fukachan Exp $
+# $FML: DataCheck.pm,v 1.18 2005/08/19 12:17:07 fukachan Exp $
#
package FML::Command::DataCheck;
@@ -149,6 +149,11 @@ sub find_anonymous_command_mail_allowed_commands
my $body = $curproc->incoming_message_body();
my $msg = $body->find_first_plaintext_message();
+ # assert
+ unless (defined $msg) {
+ return 0;
+ }
+
# XXX-TODO: use message_text_as_array_ref().
my (@body) = split(/\n/, $msg->message_text );
my $comname = '';