|
|
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 a
Length: 2547 (0x9f3)
Types: TextFile
Names: »acsapreleas3.c«
└─⟦3d0c2be1b⟧ Bits:30001254 ISODE-5.0 Tape
└─⟦eba4602b1⟧ »./isode-5.0.tar.Z«
└─⟦d3ac74d73⟧
└─⟦this⟧ »isode-5.0/acsap/acsapreleas3.c«
/* acsapreleas3.c - ACPM: interpret release */
#ifndef lint
static char *rcsid = "$Header: /f/osi/acsap/RCS/acsapreleas3.c,v 6.0 89/03/18 23:24:20 mrose Rel $";
#endif
/*
* $Header: /f/osi/acsap/RCS/acsapreleas3.c,v 6.0 89/03/18 23:24:20 mrose Rel $
*
*
* $Log: acsapreleas3.c,v $
* Revision 6.0 89/03/18 23:24:20 mrose
* Release 5.0
*
*/
/*
* 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 "ACS-types.h"
#define ACSE
#include "acpkt.h"
#ifdef DEBUG
#include "tailor.h"
#endif
/* \f
handle P-RELEASE.INDICATION */
int AcFINISHser (sd, pf, aci)
int sd;
register struct PSAPfinish *pf;
register struct AcSAPindication *aci;
{
SBV smask;
int result;
PE pe;
register struct assocblk *acb;
register struct AcSAPfinish *acf;
struct type_ACS_ACSE__apdu *pdu;
register struct type_ACS_RLRQ__apdu *rlrq;
missingP (pf);
missingP (aci);
smask = sigioblock ();
acsapPsig (acb, sd);
bzero ((char *) aci, sizeof *aci);
aci -> aci_type = ACI_FINISH;
acf = &aci -> aci_finish;
pdu = NULL;
if (pf -> pf_ninfo < 1) {
result = acsaplose (aci, ACS_PROTOCOL, NULLCP,
"no user-data on P-RELEASE");
goto out;
}
result = decode_ACS_ACSE__apdu (pe = pf -> pf_info[0], 1, NULLIP, NULLVP,
&pdu);
#ifdef DEBUG
if (result == OK && (acsap_log -> ll_events & LLOG_PDUS))
vpdu (acsap_log, print_ACS_ACSE__apdu, pe, "ACSE-apdu", 1);
#endif
pe_free (pe);
pe = pf -> pf_info[0] = NULLPE;
if (result == NOTOK) {
result = acsaplose (aci, ACS_PROTOCOL, NULLCP, "%s", PY_pepy);
goto out;
}
if (pdu -> offset != type_ACS_ACSE__apdu_rlrq) {
result = acsaplose (aci, ACS_PROTOCOL, NULLCP,
"unexpected PDU %d on P-RELEASE", pdu -> offset);
goto out;
}
rlrq = pdu -> un.rlrq;
if (rlrq -> optionals & opt_ACS_RLRQ__apdu_reason)
acf -> acf_reason = rlrq -> reason;
else
acf -> acf_reason = int_ACS_reason_normal;
result = apdu2info (acb, aci, rlrq -> user__information, acf -> acf_info,
&acf -> acf_ninfo);
out: ;
if (result == NOTOK)
freeacblk (acb);
else
acb -> acb_flags |= ACB_FINN;
PFFREE (pf);
if (pdu)
free_ACS_ACSE__apdu (pdu);
(void) sigiomask (smask);
return result;
}