|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T r
Length: 2513 (0x9d1)
Types: TextFile
Names: »rt2psabort.c«
└─⟦2d1937cfd⟧ Bits:30007241 EUUGD22: P.P 5.0
└─⟦dc59850a2⟧ »EurOpenD22/pp5.0/pp-5.tar.Z«
└─⟦e5a54fb17⟧
└─⟦this⟧ »pp-5.0/Chans/x40088/rt2psabort.c«
/* rt2psabort.c - RTPM: user abort */
# ifndef lint
static char Rcsid[] = "@(#)$Header: /cs/research/pp/hubris/pp-beta/Chans/x40088/RCS/rt2psabort.c,v 5.0 90/09/20 15:57:49 pp Exp Locker: pp $";
# endif
/*
* $Header: /cs/research/pp/hubris/pp-beta/Chans/x40088/RCS/rt2psabort.c,v 5.0 90/09/20 15:57:49 pp Exp Locker: pp $
*
* $Log: rt2psabort.c,v $
* Revision 5.0 90/09/20 15:57:49 pp
* rcsforce : 5.0 public release
*
*/
/*
* NOTICE
*
* Acquisition, use, and distribution of this module and related
* materials are subject to the restrictions of a license agreement.
* Consult the Preface in the User's Manual for the full terms of
* this agreement.
*
*/
/* LINTLIBRARY */
#include <stdio.h>
#include <signal.h>
#include <isode/rtpkt.h>
#include <isode/tailor.h>
#if ISODE < 65
/* \f
RT-U-ABORT.REQUEST */
int RtUAbortRequest (sd, data, rti)
int sd;
PE data;
struct RtSAPindication *rti;
{
SBV smask;
int result;
register struct assocblk *acb;
missingP (rti);
smask = sigioblock ();
rtsapPsig (acb, sd);
result = RtUAbortRequestAux (acb, data, rti);
(void) sigiomask (smask);
return result;
}
/* \f
*/
static int RtUAbortRequestAux (acb, data, rti)
register struct assocblk *acb;
PE data;
register struct RtSAPindication *rti;
{
int result;
PE pe,
p;
struct AcSAPindication acis;
register struct AcSAPindication *aci = &acis;
register struct AcSAPabort *aca = &aci -> aci_abort;
if (!(acb -> acb_flags & ACB_ACS))
return rtsaplose (rti, RTS_OPERATION, NULLCP,
"not an association descriptor for RTS");
/* begin RTAB APDU */
if ((pe = pe_alloc (PE_CLASS_CONT, PE_FORM_CONS, 22)) == NULLPE
|| set_add (pe, num2prim (ABORT_USER, PE_CLASS_CONT, RTAB_REASON))
== NOTOK
|| (data
&& (set_add (pe, p = pe_alloc (PE_CLASS_CONT, PE_FORM_CONS,
RTAB_USERDATA)) == NOTOK
|| set_add (p, data) == NOTOK))) {
result = rtsaplose (rti, RTS_CONGEST, NULLCP, "out of memory");
(void) AcUAbortRequest (acb -> acb_fd, NULLPEP, 0, aci);
goto out;
}
pe -> pe_context = acb -> acb_rtsid;
/* end RTAB APDU */
PLOG (rtsap_log, print_RTS_RTSE__apdus, pe, "RTABapdu", 0);
if ((result = AcUAbortRequest (acb -> acb_fd, &pe, 1, aci)) == NOTOK)
(void) acs2rtslose (acb, rti, "AcUAbortRequest", aca);
else
result = OK;
out: ;
if (pe) {
if (data)
(void) pe_extract (pe, data);
pe_free (pe);
}
return result;
}
#endif