Skip to content

Commit

Permalink
markdup: allocate i/o buf. according to docs (#169)
Browse files Browse the repository at this point in the history
  • Loading branch information
Artem Tarasov committed Mar 20, 2017
1 parent cbae927 commit f15c248
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sambamba/markdup.d
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
This file is part of Sambamba.
Copyright (C) 2012-2016 Artem Tarasov <[email protected]>
Copyright (C) 2012-2017 Artem Tarasov <[email protected]>
Sambamba is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -1263,7 +1263,7 @@ int markdup_main(string[] args) {

// marking or removing duplicates
bam = new MultiBamReader(args[1 .. $-1]);
bam.setBufferSize(io_buffer_size);
bam.setBufferSize(io_buffer_size / (args.length - 2));
auto out_stream = new BufferedFile(args[$-1], FileMode.OutNew, io_buffer_size);
auto writer = new BamWriter(out_stream, compression_level);
writer.setFilename(args[$-1]);
Expand Down

2 comments on commit f15c248

@pjotrp
Copy link
Member

@pjotrp pjotrp commented on f15c248 Mar 20, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No way there can be two items?

@lomereiter
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.