summaryrefslogtreecommitdiff
path: root/src/htslib.c
diff options
context:
space:
mode:
authorXavier Roche <xroche@users.noreply.github.com>2014-05-29 08:20:07 +0000
committerXavier Roche <xroche@users.noreply.github.com>2014-05-29 08:20:07 +0000
commitae6d05fbb30ca8c0370b2be8cc1810b028616830 (patch)
tree0b7a239bbf51f74348f52a2281020cae5e2d2575 /src/htslib.c
parent803f7b5a33c74ced027f3a171a6a7966206d4e1d (diff)
Allocation cleanup (why "+2", why ?)
Diffstat (limited to 'src/htslib.c')
-rw-r--r--src/htslib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/htslib.c b/src/htslib.c
index 9c06cd5..c058733 100644
--- a/src/htslib.c
+++ b/src/htslib.c
@@ -3081,7 +3081,7 @@ int linputsoc_t(T_SOC soc, char *s, int max, int timeout) {
}
int linput_trim(FILE * fp, char *s, int max) {
int rlen = 0;
- char *ls = (char *) malloct(max + 2);
+ char *ls = (char *) malloct(max + 1);
s[0] = '\0';
if (ls) {