Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
e10fc57
Fix a few typos in man page
jdagilliland Mar 31, 2016
d6636da
Include in man page info on read types
jdagilliland Mar 31, 2016
00e59dd
Update README.md
rmzelle Jun 10, 2016
8cc02ba
Forbid literal TAB control characters in @RG line
jblachly Aug 9, 2016
9dfb970
Add -M option to bwakit
jpfeil Nov 8, 2016
af87825
Replace u_int32_t by the more common uint32_t
jmarshall Apr 25, 2017
beff2e2
Add missing <stdint.h> include
jmarshall Apr 25, 2017
6442d00
updates grch38 URL
bwlang Apr 27, 2017
1972a97
Only realloc(pac,...) if it needs to be made larger
jmarshall May 10, 2017
6a5caf7
Fixed BWTIncFree() memory leaks
GwenIves Dec 9, 2014
7a77cc4
Fix output file parameter for samtools sort
ramyala May 18, 2017
298284d
r1144: output debugging message to stderr
lh3 Jun 8, 2017
05c5013
Merge branch 'dev'
lh3 Jun 8, 2017
ab3a92b
Prevent Clang warnings on abs() and fabs() calls
jmarshall Jun 26, 2017
d28da05
Added option to write output to file
Mar 24, 2015
bc58bf2
Add "bwa mem -o FILE" synonym and documentation
jmarshall Jun 27, 2017
5ede7eb
Update README.md
rmzelle Jun 10, 2016
a61b1dc
Expand tot_seqs variable to long long
jmarshall Jun 29, 2017
6906498
Copy the whole kstring_t even if it contains NULs
jmarshall Jun 30, 2017
bcb475c
In bsw2_stat(), fail to infer when no pairs are within boundaries
jmarshall Jun 30, 2017
3b96dce
Mem should set the mate cigar tag.
nh13 Jun 25, 2017
c56c2e4
Several trivial Debian patches
tillea Jul 12, 2015
87ed015
Merge pull request #141 from jmarshall/bwasw-nan
lh3 Jul 30, 2017
4989736
Merge pull request #123 from bwlang/patch-1
lh3 Jul 30, 2017
31bf49d
Merge pull request #96 from jpfeil/master
lh3 Jul 30, 2017
a54e769
Merge pull request #70 from rmzelle/patch-1
lh3 Jul 30, 2017
0976272
Merge pull request #139 from jmarshall/fixes
lh3 Jul 30, 2017
89a5c0c
moved BWTFree() into BWTIncFree()
lh3 Jul 30, 2017
24a8d66
removed drone.io
lh3 Jul 30, 2017
1eee77a
Merge pull request #84 from jblachly/readgroupfix
lh3 Jul 30, 2017
83260cc
Merge pull request #60 from jdagilliland/typo
lh3 Jul 30, 2017
950ea8c
Merge pull request #138 from nh13/nh_mem_mate_cigar
lh3 Jul 30, 2017
5d15c8b
Merge pull request #129 from lexentbio/bwakit_fix_sort
lh3 Jul 30, 2017
47d9fb2
Release 0.7.16-r1180
lh3 Jul 31, 2017
a9c688a
r1181: fixed a segfault (#145) due to (#138)
lh3 Jul 31, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Only realloc(pac,...) if it needs to be made larger
Similarly to the realloc(pac,...) within add1(), only bother to call
realloc() if appending the reverse complemented sequence requires more
space than is currently in the pac/m_pac buffer.

Avoids realloc(pac,0) (and a "Failed to allocate 0 bytes at bntseq.c"
message from wrap_realloc()) in the corner case of an empty reference
FASTA file.  Fixes lh3#54.
  • Loading branch information
jmarshall committed May 10, 2017
commit 1972a978133110e36af05a6bc2e27881f51443c4
6 changes: 3 additions & 3 deletions bntseq.c
Original file line number Diff line number Diff line change
Expand Up @@ -299,9 +299,9 @@ int64_t bns_fasta2bntseq(gzFile fp_fa, const char *prefix, int for_only)
// read sequences
while (kseq_read(seq) >= 0) pac = add1(seq, bns, pac, &m_pac, &m_seqs, &m_holes, &q);
if (!for_only) { // add the reverse complemented sequence
m_pac = (bns->l_pac * 2 + 3) / 4 * 4;
pac = realloc(pac, m_pac/4);
memset(pac + (bns->l_pac+3)/4, 0, (m_pac - (bns->l_pac+3)/4*4) / 4);
int64_t ll_pac = (bns->l_pac * 2 + 3) / 4 * 4;
if (ll_pac > m_pac) pac = realloc(pac, ll_pac/4);
memset(pac + (bns->l_pac+3)/4, 0, (ll_pac - (bns->l_pac+3)/4*4) / 4);
for (l = bns->l_pac - 1; l >= 0; --l, ++bns->l_pac)
_set_pac(pac, bns->l_pac, 3-_get_pac(pac, l));
}
Expand Down