|
|
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 s
Length: 1398 (0x576)
Types: TextFile
Names: »ssdu2pe.c«
└─⟦3d0c2be1b⟧ Bits:30001254 ISODE-5.0 Tape
└─⟦eba4602b1⟧ »./isode-5.0.tar.Z«
└─⟦d3ac74d73⟧
└─⟦this⟧ »isode-5.0/psap/ssdu2pe.c«
/* ssdu2pe.c - read a PE from SSDU */
#ifndef lint
static char *rcsid = "$Header: /f/osi/psap/RCS/ssdu2pe.c,v 6.0 89/03/18 23:39:23 mrose Rel $";
#endif
/*
* $Header: /f/osi/psap/RCS/ssdu2pe.c,v 6.0 89/03/18 23:39:23 mrose Rel $
*
*
* $Log: ssdu2pe.c,v $
* Revision 6.0 89/03/18 23:39:23 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 "psap.h"
#include "tailor.h"
/* \f
*/
PE ssdu2pe (base, len, realbase, result)
char *base,
*realbase;
int len;
int *result;
{
register PE pe;
register PS ps;
if ((ps = ps_alloc (str_open)) == NULLPS) {
*result = PS_ERR_NMEM;
return NULLPE;
}
if (str_setup (ps, base, len, 1) == OK) {
if (!realbase)
ps -> ps_inline = 0;
if (pe = ps2pe (ps)) {
if (realbase)
pe -> pe_realbase = realbase;
ps -> ps_errno = PS_ERR_NONE;
}
else
if (ps -> ps_errno == PS_ERR_NONE)
ps -> ps_errno = PS_ERR_EOF;
}
*result = ps -> ps_errno;
ps -> ps_inline = 1;
ps_free (ps);
#ifdef DEBUG
if (pe && (psap_log -> ll_events & LLOG_PDUS))
pe2text (psap_log, pe, 1, len);
#endif
return pe;
}