DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: ┃ T g

⟦6f3cd4640⟧ TextFile

    Length: 1166 (0x48e)
    Types: TextFile
    Names: »get_f.c«

Derivation

└─⟦8ee07855d⟧ Bits:30000545 8mm tape, Rational 1000, DTIA 2_1_6
    └─ ⟦0c25cb74a⟧ »DATA« 
        └─⟦038380b96⟧ 
└─⟦d0624311f⟧ Bits:30000529 8mm tape, Rational 1000, DTIA 2_1_7
    └─ ⟦f494b5154⟧ »DATA« 
        └─⟦038380b96⟧ 
            └─ ⟦this⟧ »get_f.c« 
└─⟦8ee07855d⟧ Bits:30000545 8mm tape, Rational 1000, DTIA 2_1_6
    └─ ⟦0c25cb74a⟧ »DATA« 
        └─⟦0732ea0cf⟧ 
└─⟦d0624311f⟧ Bits:30000529 8mm tape, Rational 1000, DTIA 2_1_7
    └─ ⟦f494b5154⟧ »DATA« 
        └─⟦0732ea0cf⟧ 
            └─ ⟦this⟧ »../../dtia/release_apollo_2.1/get_f.c« 
└─⟦8ee07855d⟧ Bits:30000545 8mm tape, Rational 1000, DTIA 2_1_6
    └─ ⟦0c25cb74a⟧ »DATA« 
        └─⟦25fab149a⟧ 
└─⟦d0624311f⟧ Bits:30000529 8mm tape, Rational 1000, DTIA 2_1_7
    └─ ⟦f494b5154⟧ »DATA« 
        └─⟦25fab149a⟧ 
            └─ ⟦this⟧ »../../dtia/release_sun_2.1/get_f.c« 
└─⟦8ee07855d⟧ Bits:30000545 8mm tape, Rational 1000, DTIA 2_1_6
    └─ ⟦0c25cb74a⟧ »DATA« 
        └─⟦be254d495⟧ 
└─⟦d0624311f⟧ Bits:30000529 8mm tape, Rational 1000, DTIA 2_1_7
    └─ ⟦f494b5154⟧ »DATA« 
        └─⟦be254d495⟧ 
            └─ ⟦this⟧ »../../dtia/release_aix_2.1/get_f.c« 
└─⟦8ee07855d⟧ Bits:30000545 8mm tape, Rational 1000, DTIA 2_1_6
    └─ ⟦0c25cb74a⟧ »DATA« 
        └─⟦c67979795⟧ 
└─⟦d0624311f⟧ Bits:30000529 8mm tape, Rational 1000, DTIA 2_1_7
    └─ ⟦f494b5154⟧ »DATA« 
        └─⟦c67979795⟧ 
            └─ ⟦this⟧ »../../dtia/release_hp_2.1/get_f.c« 

TextFile

#ifndef	lint
#ifndef	DEBUG
static char SCCS_id[] = "@(#)get_f.c 2.1 90/08/02 19:04:29  Copyright(c) 1990 by Rational.";
#else
static char SCCS_id[] = "@(#)get_f.c DEBUG 2.1 90/08/02 19:04:29  Copyright(c) 1990 by Rational.";
#endif
#endif

#define	GET_F	
#include	"talk.h"
#undef	GET_F	

extern	int	errno;
static	int	error_number = E_OK;
static	int	fd = -1;

#define	LG_BUFFER	MAX_SIZE_ITEM
static	char	buffer[LG_BUFFER];
static	int	lg_buffer=0;

int	get_f_from_remote_file_in(name)
char	*name; 
{
	error_number = E_OK;
	fd = open(name,O_RDONLY);
	if (fd == -1)	error_number = errno;
	lg_buffer=0;
	return E_OK;
}

int	get_f_end_iter_i(no_iter)
int	no_iter; 
{
	if (fd == -1) 		return TRUE;
	if (lg_buffer<0)	return	TRUE;
	if (lg_buffer==0) {
		lg_buffer=read(fd,buffer,LG_BUFFER);
		if 	(lg_buffer == -1)	error_number = errno;
		if	(lg_buffer<=0)	return	TRUE;
	}
	return	FALSE;
}

int	get_f_options_in(options)
char	*options; 
{
	return	E_OK;
}

int	get_f_content_out(iter1,get,lg_get)
int	iter1;
char	**get;
int	*lg_get; 
{
	*get=buffer;
	*lg_get=lg_buffer;
	lg_buffer=0;
	return E_OK;
}

int	get_f_end() {
	if (fd != -1) {
		close(fd);
	}
	return	error_number;
}