|
|
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: 732 (0x2dc)
Types: TextFile
Names: »readk.c«
└─⟦b20c6495f⟧ Bits:30007238 EUUGD18: Wien-båndet, efterår 1987
└─⟦this⟧ »EUUGD18/General/Adventure/src/kio/readk.c«
/*
** Copyright (c) 1985 Ken Wellsch
**
** Permission is hereby granted to all users to possess, use, copy,
** distribute, and modify the programs and files in this package
** provided it is not for direct commercial benefit and secondly,
** that this notice and all modification information be kept and
** maintained in the package.
**
*/
#include "kio.h"
int readk (unit,key,buffer,size)
int unit, key, size ;
char *buffer ;
{
struct mkey k ;
MapKey (key,&k) ;
if ( GetBlk (k.b) != k.b || Iblk.i_siz[k.e] == 0 )
return (ERROR) ;
if ( Iblk.i_siz[k.e] > size )
error ("Readk","buffer too small (%d<%d)!",size,Iblk.i_siz[k.e]) ;
return (GetRec(Iblk.i_loc[k.e],buffer,Iblk.i_siz[k.e])) ;
}