  
                      if (0 == addFrontClipping) {
 diff -rupN -x Xcode -x .git tmp/snap/SNAPLib/SAM.cpp snap/SNAPLib/SAM.cpp
---- tmp/snap/SNAPLib/SAM.cpp	2015-07-28 15:15:02.000000000 -0400
-+++ snap/SNAPLib/SAM.cpp	2015-08-16 20:31:16.000000000 -0400
+--- tmp/snap/SNAPLib/SAM.cpp	2016-01-18 14:55:36.000000000 -0500
++++ snap/SNAPLib/SAM.cpp	2016-01-18 15:15:58.000000000 -0500
 @@ -1123,6 +1123,7 @@ SAMFormat::writeRead(
      Read * read,
      AlignmentResult result, 

 
     static int compareByContigAndScore(const void *first, const void *second);      // qsort()-style compare routine
     static int compareByScore(const void *first, const void *second);               // qsort()-style compare routine
@@ -81,6 +128,8 @@ struct PairedAlignmentResult {
 	int score[NUM_READS_PER_PAIR];              // score of each end if matched
 
 	int mapq[NUM_READS_PER_PAIR];               // mapping quality of each end, encoded like a Phred score (but as an integer, not ASCII Phred + 33).

         bool hasMate = false, bool firstInPair = false, Read * mate = NULL, 
         AlignmentResult mateResult = NotFound, GenomeLocation mateLocation = 0, Direction mateDirection = FORWARD,
         bool alignedAsPair = false) const; 
diff -rupN -x Xcode -x .git tmp/snap/SNAPLib/SortedDataWriter.cpp snap/SNAPLib/SortedDataWriter.cpp
--- tmp/snap/SNAPLib/SortedDataWriter.cpp	2016-01-18 14:51:10.000000000 -0500
+++ snap/SNAPLib/SortedDataWriter.cpp	2016-01-18 14:44:34.000000000 -0500
@@ -335,7 +335,7 @@ SortedDataFilterSupplier::mergeSort()
     }
     for (SortBlockVector::iterator i = blocks.begin(); i != blocks.end(); i++) {
         i->reader = readerSupplier->getDataReader(1, MAX_READ_LENGTH * 8, 0.0,
-            min(1UL << 23, max(1UL << 17, bufferSpace / blocks.size()))); // 128kB to 8MB buffer space per block
+            min(1ULL << 23, max(1ULL << 17, bufferSpace / blocks.size()))); // 128kB to 8MB buffer space per block
         i->reader->init(tempFileName);
         i->reader->reinit(i->start, i->bytes);
     }
diff -rupN -x Xcode -x .git tmp/snap/SNAPLib/directions.h snap/SNAPLib/directions.h
--- tmp/snap/SNAPLib/directions.h	2016-01-18 14:51:10.000000000 -0500
+++ snap/SNAPLib/directions.h	2015-10-12 16:54:59.000000000 -0400
@@ -33,4 +33,4 @@ const int RC = 1;
 inline Direction OppositeDirection(Direction direction) {
     _ASSERT(FORWARD == direction || RC == direction);
     return 1-direction;
-}
\ No newline at end of file
+}
