예제 #1
0
파일: fio.c 프로젝트: ryo/netbsd-src
/*
 * Return a file buffer all ready to read up the
 * passed message pointer.
 */
PUBLIC FILE *
setinput(const struct message *mp)
{

    (void)fflush(otf);
    if (fseek(itf, (long)positionof(mp->m_block, mp->m_offset), SEEK_SET) < 0)
        err(EXIT_FAILURE, "fseek");
    return itf;
}
예제 #2
0
파일: fio.c 프로젝트: coyizumi/cs111
/*
 * Return a file buffer all ready to read up the
 * passed message pointer.
 */
FILE *
setinput(struct message *mp)
{

	(void)fflush(otf);
	if (fseeko(itf,
		   positionof(mp->m_block, mp->m_offset), SEEK_SET) < 0)
		err(1, "fseeko");
	return (itf);
}
예제 #3
0
/*
 * Return a file buffer all ready to read up the
 * passed message pointer.
 */
FILE *
setinput(struct message *mp)
{

	fflush(otf);
	if (fseek(itf, (long)positionof(mp->m_block, mp->m_offset), SEEK_SET)
	    < 0)
		err(1, "fseek");
	return(itf);
}