Merge pull request #231 from alexwangx/alexwang
fixed issue #227 , fixed Mysql5.1.73 throw NullPointerException
This commit is contained in:
+3
-2
@@ -279,8 +279,9 @@ public class MysqlConnection implements ErosaConnection {
|
||||
}
|
||||
|
||||
List<String> columnValues = rs.getFieldValues();
|
||||
if(columnValues.get(0).toUpperCase().equals("CRC32")){
|
||||
binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_CRC32;
|
||||
if (columnValues.size() > 0 && columnValues.get(0) != null
|
||||
&& columnValues.get(0).toUpperCase().equals("CRC32")) {
|
||||
binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_CRC32;
|
||||
}else{
|
||||
binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_OFF;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user