Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fastq-mcf sink into dead circulation when getopt_long #71

Open
songdongmei opened this issue Oct 9, 2018 · 0 comments
Open

fastq-mcf sink into dead circulation when getopt_long #71

songdongmei opened this issue Oct 9, 2018 · 0 comments

Comments

@songdongmei
Copy link

songdongmei commented Oct 9, 2018

When I run fastq-mcf with the following command:
./fastq-mcf /home/adapters/TruSeq3-PE.fa /home/data/test.read1.fq
, it seems the program sink into dead circulation.

I use gdb to debug what happened, then navigate to this location:
271 while ( (c = getopt_long(argc, argv, "-nf0uXUVHKSRdbehp:o:O:l:s:m:t:k:x:P:q:L:C:w:F:D:",long_options,&option_inde x)) != -1) {
after all options( in my case, it means adapter file and reads file ) are gotten, value of variable "c" becomes "255", not "-1", so it can't get out of the while loop.

And I man getopt_long function, it shows that return value of this function is "int" type.
But in fastq-mcf.cpp, it defines return value as "char" type
203 char c;

I change this line, and fastq-mcf could work correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant