Changeset 3409 for trunk/yat/omic/BamHeader.cc
- Timestamp:
- Apr 17, 2015, 3:07:04 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/yat/omic/BamHeader.cc
r3408 r3409 25 25 26 26 #include "yat/utility/Exception.h" 27 28 // we need to include 'sam_header.h' when compiling against libbam 29 #ifndef YAT_HAVE_HTSLIB 30 #if YAT_HAVE_SAM_H 31 #include <sam_header.h> 32 #elif YAT_HAVE_BAM_BAM_H 33 #include <bam/sam_header.h> 34 #elif YAT_HAVE_SAMTOOLS_SAM_H 35 #include <samtools/sam_header.h> 36 #else 37 #error cannot end up here 38 #endif 39 #endif 27 40 28 41 #include <cassert> … … 118 131 } 119 132 133 120 134 void BamHeader::text(const std::string& txt) 121 135 { … … 130 144 memcpy(header_->text, txt.c_str(), txt.size()+1); 131 145 #ifndef YAT_HAVE_HTSLIB 146 // destroy dict to ensure that things are updated during parsing 147 if (header_->dict) { 148 sam_header_free(header_->dict); 149 header_->dict = 0; 150 } 132 151 sam_header_parse(header_); 133 152 #endif
Note: See TracChangeset
for help on using the changeset viewer.