Seems to me your code has some flaws but should work.
You can check wich part of your function is executed if you place printf statements in each part.
Like this:
Code:
printf("combo-0");


or
Code:
printf("combo-1");