STATUS CS_suspend_session_set( i4 offset, i4 lsbuf, char *sbuf, i4 size, PTR object ) { CS_SCB *an_scb; STATUS stat; stat = CS_mod_session( sbuf, &an_scb ); if( stat == OK && (stat = CS_is_internal( an_scb )) == OK ) an_scb->cs_state = CS_UWAIT; return( stat ); }
STATUS CS_rm_session_set(i4 offset, i4 lsbuf, char *sbuf, i4 size, PTR object) { CS_SCB *an_scb; STATUS stat; stat = CS_mod_session(sbuf, &an_scb); if (stat == OK && (stat = CS_is_internal(an_scb)) == OK) { CSremove((i4 ) an_scb->cs_self); CSattn(CS_REMOVE_EVENT, (i4 ) an_scb->cs_self); } return (stat); }
/*{ ** Name: CS_debug_set - set function debugging a thread ** ** Description: ** Dumps debug information about the thread. May only ** be called by the owner or a super user. ** ** Re-entrancy: ** yes. ** ** Inputs: ** offset ignored ** lsbuf ignored ** sbuf ignored ** size ignored ** object the SCB in question ** ** Outputs: ** none ** ** Side Effects: ** Debug information about the thread is dumped ** to the server log. ** ** Returns: ** OK dump attempted. ** MO_NO_INSTANCE bogus SCB ** MO_NO_WRITE no permission to dump it. ** ** History: ** 28-Oct-1992 (daveb) ** documentd. */ STATUS CS_debug_set(i4 offset, i4 lsbuf, char *sbuf, i4 size, PTR object) { CS_SCB *an_scb; STATUS stat; stat = CS_mod_session(sbuf, &an_scb); if (stat == OK) { /* FIXME -- what do do here? */ # if 0 char buffer[1048]; CS_fmt_scb(an_scb, sizeof(buffer), buffer); CS_dump_stack(an_scb, output_fcn); # endif } return (stat); }
STATUS CS_resume_session_set(i4 offset, i4 lsbuf, char *sbuf, i4 size, PTR object) { CS_SCB *an_scb; STATUS stat; stat = CS_mod_session(sbuf, &an_scb); if (stat == OK && (stat = CS_is_internal(an_scb)) == OK) { if (an_scb->cs_state != CS_UWAIT) { /* FIXME -- better status */ /* "Session %x was not suspended", */ stat = FAIL; } else { an_scb->cs_state = CS_COMPUTABLE; } } return (stat); }