This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
perl 5.0 alpha 2
[perl5.git]
/
do
/
tell
1
long
2
do_tell(stab)
3
STAB *stab;
4
{
5
register STIO *stio;
6
7
if (!stab)
8
goto phooey;
9
10
stio = stab_io(stab);
11
if (!stio || !stio->ifp)
12
goto phooey;
13
14
#ifdef ULTRIX_STDIO_BOTCH
15
if (feof(stio->ifp))
16
(void)fseek (stio->ifp, 0L, 2); /* ultrix 1.2 workaround */
17
#endif
18
19
return ftell(stio->ifp);
20
21
phooey:
22
if (dowarn)
23
warn("tell() on unopened file");
24
errno = EBADF;
25
return -1L;
26
}
27