Update of /cvsroot/popfile/engine/Classifier
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12298/Classifier
Modified Files:
Bayes.pm
Log Message:
Fix bug that prevented magnets containing quote characters from being deleted.
Index: Bayes.pm
===================================================================
RCS file: /cvsroot/popfile/engine/Classifier/Bayes.pm,v
retrieving revision 1.351
retrieving revision 1.352
diff -C2 -d -r1.351 -r1.352
*** Bayes.pm 27 Feb 2006 12:24:49 -0000 1.351
--- Bayes.pm 31 Aug 2007 14:15:28 -0000 1.352
***************
*** 4249,4257 ****
my $mtid = $result->[0];
$self->db_()->do( "delete from magnets
where magnets.bucketid = $bucketid and
magnets.mtid = $mtid and
! magnets.val = '$text';" );
}
--- 4249,4258 ----
my $mtid = $result->[0];
+ $text = $self->db_()->quote( $text );
$self->db_()->do( "delete from magnets
where magnets.bucketid = $bucketid and
magnets.mtid = $mtid and
! magnets.val = $text;" );
}
|