Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

ftell_.c

Go to the documentation of this file.
00001 #include "f2c.h"
00002 #include "fio.h"
00003 
00004  static FILE *
00005 #ifdef KR_headers
00006 unit_chk(unit, who) integer unit; char *who;
00007 #else
00008 unit_chk(integer unit, char *who)
00009 #endif
00010 {
00011         if (unit >= MXUNIT || unit < 0)
00012                 f__fatal(101, who);
00013         return f__units[unit].ufd;
00014         }
00015 
00016  integer
00017 #ifdef KR_headers
00018 ftell_(unit) integer *unit;
00019 #else
00020 ftell_(integer *unit)
00021 #endif
00022 {
00023         FILE *f;
00024         return (f = unit_chk(*unit, "ftell")) ? ftell(f) : -1L;
00025         }
00026 
00027  int
00028 #ifdef KR_headers
00029 fseek_(unit, offset, whence) integer *unit, *offset, *whence;
00030 #else
00031 fseek_(integer *unit, integer *offset, integer *whence)
00032 #endif
00033 {
00034         FILE *f;
00035         return  !(f = unit_chk(*unit, "fseek"))
00036                 || fseek(f, *offset, (int)*whence) ? 1 : 0;
00037         }
 

Powered by Plone

This site conforms to the following standards: