1*21363Sdist /* 2*21363Sdist * Copyright (c) 1983 Regents of the University of California. 3*21363Sdist * All rights reserved. The Berkeley software License Agreement 4*21363Sdist * specifies the terms and conditions for redistribution. 5*21363Sdist */ 6*21363Sdist 713582Ssam #ifndef lint 8*21363Sdist static char sccsid[] = "@(#)telldir.c 5.1 (Berkeley) 05/30/85"; 9*21363Sdist #endif not lint 105929Smckusick 116370Smckusic #include <sys/param.h> 1213582Ssam #include <sys/dir.h> 135929Smckusick 145929Smckusick /* 155929Smckusick * return a pointer into a directory 165929Smckusick */ 175929Smckusick long 185929Smckusick telldir(dirp) 195929Smckusick DIR *dirp; 205929Smckusick { 2111827Smckusick extern long lseek(); 2211827Smckusick 235929Smckusick return (lseek(dirp->dd_fd, 0L, 1) - dirp->dd_size + dirp->dd_loc); 245929Smckusick } 25