PRMdel.pas/-au=
{
DATE : 

AUTHOR : 
     Kenneth G. Tibesar
     3M Engineering Systems and Technology Labs
     3M Center, Bldg 518-1
     St. Paul, Minn. 55144

REVISION HISTORY :

  DATE     BY      DESCRIPTION

08-JUL-81  KGT     Check to see if file has been opened or created properly 
                   before executing the record operation.  An available field
                   in the FAB (CTX) is set to a +1 if PRMOpe or PRMCre
                   was successful.

DESCRIPTION :

ENVIROMENT :          
     DEC PDP-11 
     RSX-11M or RSX-11M+

}


{$E+ External procedure}
{$C
	.TITLE	PrmDEL
	.IDENT	"810708"
}
@prmconst.pas
TYPE
@RMSTYPE.PAS
@Fab.pas
@rab.pas
@PrmType.pas

PROCEDURE PrmDel ( VAR FileBuf : RmsFileDesc ;
                   VAR Status  : RmsStatus ) ;
BEGIN
WITH FileBuf DO
  IF Fab.Ctx <> 1 
    THEN Status[1] := PrINI 	{ file not properly initialized }
    ELSE
      BEGIN
      {$C
        .mcall $delete
        mov FileBuf(sp), r0		; FileBuf address
        ADD #Rab, r0		; calc address of the rab
        $delete r0			; Delete the record
      }
        Status[1] := FileBuf.Rab.Sts ;
        Status[2] := FileBuf.Rab.Stv ;
      END ;
END; { rms delete }
/
