# set BamTools version information
set (BamTools_VERSION_MAJOR 2)
set (BamTools_VERSION_MINOR 0)
-set (BamTools_VERSION_BUILD 4)
+set (BamTools_VERSION_BUILD 5)
# set our library and executable destination dirs
set (EXECUTABLE_OUTPUT_PATH "${CMAKE_SOURCE_DIR}/bin")
# This could be handy for archiving the generated documentation or
# if some version control system is used.
-PROJECT_NUMBER = 2.0.4
+PROJECT_NUMBER = 2.0.5
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
# base path where the generated documentation will be put.
return true;
// get the storage class and find the next tag
- if ( *pTagStorageType == '\0' ) return false;
- if ( !SkipToNextTag(*pTagStorageType, pTagData, numBytesParsed) ) return false;
- if ( *pTagData == '\0' ) return false;
+ if ( *pTagStorageType == '\0' ) {
+ ErrorString = "unexpected null found - 1";
+ return false;
+ }
+ if ( !SkipToNextTag(*pTagStorageType, pTagData, numBytesParsed) ) {
+ ErrorString = "could not skip to next tag";
+ return false;
+ }
+ if ( *pTagData == '\0' ) {
+ ErrorString = "unexpected null found - 2";
+ return false;
+ }
}
// checked all tags, none match
// BamAlignment.h (c) 2009 Derek Barnett
// Marth Lab, Department of Biology, Boston College
// ---------------------------------------------------------------------------
-// Last modified: 12 October 2011 (DB)
+// Last modified: 16 October 2011 (DB)
// ---------------------------------------------------------------------------
// Provides the BamAlignment data structure
// ***************************************************************************
unsigned int numBytesParsed = 0;
// return failure if tag not found
- if ( FindTag(tag, pTagData, tagDataLength, numBytesParsed) ) {
+ if ( !FindTag(tag, pTagData, tagDataLength, numBytesParsed) ) {
// TODO: set error string?
return false;
}
unsigned int numBytesParsed = 0;
// return failure if tag not found
- if ( FindTag(tag, pTagData, tagDataLength, numBytesParsed) ) {
+ if ( !FindTag(tag, pTagData, tagDataLength, numBytesParsed) ) {
// TODO: set error string?
return false;
}
// BamConstants.h (c) 2011 Derek Barnett
// Marth Lab, Department of Biology, Boston College
// ---------------------------------------------------------------------------
-// Last modified: 10 October 2011 (DB)
+// Last modified: 16 October 2011 (DB)
// ---------------------------------------------------------------------------
// Provides basic constants for handling BAM files.
// ***************************************************************************
// BAM tag types & sizes
const char BAM_TAG_TYPE_ASCII = 'A';
-const char BAM_TAG_TYPE_UINT8 = 'c';
-const char BAM_TAG_TYPE_INT8 = 'C';
-const char BAM_TAG_TYPE_UINT16 = 's';
-const char BAM_TAG_TYPE_INT16 = 'S';
-const char BAM_TAG_TYPE_UINT32 = 'i';
-const char BAM_TAG_TYPE_INT32 = 'I';
+const char BAM_TAG_TYPE_INT8 = 'c';
+const char BAM_TAG_TYPE_UINT8 = 'C';
+const char BAM_TAG_TYPE_INT16 = 's';
+const char BAM_TAG_TYPE_UINT16 = 'S';
+const char BAM_TAG_TYPE_INT32 = 'i';
+const char BAM_TAG_TYPE_UINT32 = 'I';
const char BAM_TAG_TYPE_FLOAT = 'f';
const char BAM_TAG_TYPE_STRING = 'Z';
const char BAM_TAG_TYPE_HEX = 'H';
template<>
struct TagTypeHelper<uint16_t> {
- static bool CanCovnertFrom(const char c) {
+ static bool CanConvertFrom(const char c) {
return ( c == Constants::BAM_TAG_TYPE_ASCII ||
c == Constants::BAM_TAG_TYPE_UINT8 ||
c == Constants::BAM_TAG_TYPE_UINT16 );
# create main BamTools API shared library
add_library( BamTools SHARED ${BamToolsAPISources} )
-set_target_properties( BamTools PROPERTIES SOVERSION "2.0.4" )
+set_target_properties( BamTools PROPERTIES SOVERSION "2.0.5" )
set_target_properties( BamTools PROPERTIES OUTPUT_NAME "bamtools" )
# create main BamTools API static library