while (fastq_next(fqf, seq)) {
rc = pcre_exec(re, /* pattern */
- NULL, /* extre data */
+ NULL, /* extra data */
id_flag ? seq->id1.s : seq->seq.s,
id_flag ? seq->id1.n : seq->seq.n,
0, /* subject offset */
ovector, /* output vector */
3 ); /* output vector length */
- if ((invert_flag && rc == PCRE_ERROR_NOMATCH) || rc >= 0) {
+ if ((invert_flag && rc == PCRE_ERROR_NOMATCH) || (!invert_flag && rc >= 0)) {
if (count_flag) count++;
else fastq_print(fout, seq);
}
while (1) {
opt = getopt_long(argc, argv, "ivchV", long_options, &opt_idx);
- if( opt == -1 ) break;
+ if (opt == -1) break;
switch (opt) {
case 0: