Bug fixes for the bwa aligner and changes to support compiling against newer releases of the bwa code base.

git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@4863 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
handsake 2010-12-17 14:49:15 +00:00
parent 0d18bd1011
commit 21dc05138a
2 changed files with 5 additions and 2 deletions

View File

@ -208,7 +208,7 @@ void BWA::load_default_options()
} }
void BWA::set_max_edit_distance(float edit_distance) { void BWA::set_max_edit_distance(float edit_distance) {
if(edit_distance < 1) { if(edit_distance > 0 && edit_distance < 1) {
options.fnr = edit_distance; options.fnr = edit_distance;
options.max_diff = -1; options.max_diff = -1;
} }
@ -246,6 +246,9 @@ bwa_seq_t* BWA::create_sequence(const char* bases, const unsigned read_length)
sequence->cigar = NULL; sequence->cigar = NULL;
sequence->n_cigar = 0; sequence->n_cigar = 0;
sequence->multi = NULL;
sequence->n_multi = 0;
return sequence; return sequence;
} }

View File

@ -59,7 +59,7 @@ public class BWACAligner extends BWAAligner {
*/ */
@Override @Override
public void updateConfiguration(BWAConfiguration configuration) { public void updateConfiguration(BWAConfiguration configuration) {
if(thunkPointer != 0) if(thunkPointer == 0)
throw new ReviewedStingException("BWA/C: attempting to update configuration of uninitialized aligner."); throw new ReviewedStingException("BWA/C: attempting to update configuration of uninitialized aligner.");
updateConfiguration(thunkPointer,configuration); updateConfiguration(thunkPointer,configuration);
} }