Something about this warning makes it reference a bad pointer and crash
during periods of extremely high load. I don't know why, but just leaving
it alone seems to fix the problem.
}
time(&last_purge);
- //if (try_critical_section(S_SESSION_TABLE))
- //return;
- //
begin_critical_section(S_SESSION_TABLE);
ptr = ContextList;
while (ptr) {
ptr2->next = rem;
rem = ptr2;
}
- else if (ptr2->kill_me) {
- syslog(LOG_DEBUG, "context: session %d is timed out but non-idle", ptr->cs_pid);
- }
+ //else if (ptr2->kill_me) {
+ //syslog(LOG_DEBUG, "context: session %d is timed out but non-idle", ptr->cs_pid);
+ //}
}
end_critical_section(S_SESSION_TABLE);
long ops = 0;
printf("\033[%d;%dH\033[32m--------\033[0m", row, col);
fflush(stdout);
- sleep(1);
+ sleep(5);
while(1) {
perform_random_thing(serv_sock);
printf("\033[%d;%dH\033[33m%8ld\033[0m", row, col, ++ops);