Moved process count-down to terminate function for the C RTS
Moved process count-down to terminate function for the C RTS

Some threads exit by finishing the runThread function, and some finish
by calling idris_stopThread. The test io003 triggered the assert in
runThread. Bring back calling terminate from the end of runThread.

kojiromike/Idris-dev,kojiromike/Idris-dev,kojiromike/Idris-dev,kojiromike/Idris-dev,kojiromike/Idris-dev,kojiromike/Idris-dev