Но почему так происходит - предыдущие потоки не завершаются или иная причина? Для всех, я так предполагаю, потоков выполняется pthread_join(), так что они вроде как должны завершаться.the number 11 stands for EAGAIN which in turn means "The system lacked the necessary resources to create another thread, or the system-imposed limit on the total number of threads in a process PTHREAD_THREADS_MAX would be exceeded."
Спасибо.