}
end_critical_section(S_SESSION_TABLE);
if (killed > 0)
- CtdlLogPrintf(CTDL_INFO, "Terminated %d idle sessions\n", killed);
+ CtdlLogPrintf(CTDL_INFO, "Scheduled %d idle sessions for termination\n", killed);
if (longrunners > 0)
CtdlLogPrintf(CTDL_INFO, "Didn't terminate %d protected idle sessions;\n", killed);
}
* If the client is still connected, blow 'em away.
* if the socket is 0, its already gone or was never there.
*/
- CtdlLogPrintf(CTDL_DEBUG, "Closing socket %d\n", con->client_socket);
if (con->client_socket != 0)
{
+ CtdlLogPrintf(CTDL_DEBUG, "Closing socket %d\n", con->client_socket);
close(con->client_socket);
}
me->ldap_dn = NULL;
me->session_specific_data = NULL;
+ me->download_fp = NULL;
+ me->upload_fp = NULL;
+ me->client_socket = 0;
+
me->MigrateBuf = NewStrBuf();
me->RecvBuf.Buf = NewStrBuf();
-
+
begin_critical_section(S_SESSION_TABLE);
{
me->cs_pid = ++next_pid;
len = cutuserkey(sysname);
memcpy(context->curr_user, sysname, len + 1);
context->client_socket = (-1);
+ context->state = CON_SYS;
+ context->ServiceName = name;
/* internal_create_user has the side effect of loading the user regardless of wether they
* already existed or needed to be created
rem = ptr->next;
--num_sessions;
- CtdlLogPrintf(CTDL_DEBUG, "Purging session %d\n", ptr->cs_pid);
+ CtdlLogPrintf(CTDL_DEBUG, "Purging session #%d %s\n", ptr->cs_pid, ptr->ServiceName);
RemoveContext(ptr);
free (ptr);
ptr = rem;