diff options
author | Calvin Morrison <mutantturkey@gmail.com> | 2013-09-16 10:31:53 -0400 |
---|---|---|
committer | Calvin Morrison <mutantturkey@gmail.com> | 2013-09-16 10:31:53 -0400 |
commit | ad0b22e1e5124cf614c6ca44e503270d6650c45d (patch) | |
tree | 67ce44fa102e2e7379a90c239c8bd9faf1070364 | |
parent | 0a9476fe2aa09610a23b2a54974bbb733b478a92 (diff) |
don't use strlen instead just use the read variable set by getline
-rwxr-xr-x | count_nucleobases.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/count_nucleobases.c b/count_nucleobases.c index c2aafe5..3fd6aec 100755 --- a/count_nucleobases.c +++ b/count_nucleobases.c @@ -25,7 +25,7 @@ int main(int argc, char **argv) { while ((read = getline(&line, &len, fh)) != -1) { if(line[0] != '>') { unsigned int i = 0; - for(i = 0; i < strlen(line); i++) { + for(i = 0; i < read; i++) { counts[line[i]]++; } } |