seekdir

Section: C Library Functions (3)
Updated: 2026-02-08
Index JM Home Page roff page
 

名前

seekdir - 次の readdir() 呼び出し用にディレクトリストリーム中の位置を設定する  

ライブラリ

標準 C ライブラリ (libc,~-lc)  

書式

#include <dirent.h>

void seekdir(DIR *dirp, long loc);

glibc 向けの機能検査マクロの要件 (feature_test_macros(7) 参照):

seekdir():

    _XOPEN_SOURCE
        || /* glibc >= 2.19: */ _DEFAULT_SOURCE
        || /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE
 

説明

seekdir() 関数は、 readdir(3) の次の呼び出しでの開始位置となる、ディレクトリストリーム中での位置を設定する。 loc 引数には、それ以前の telldir(3) の呼び出しで返された値を渡すべきである。  

返り値

seekdir() 関数は、値を返さない。  

属性

この節で使用されている用語の説明については、 attributes(7) を参照。
インターフェース属性値
seekdir() Thread safetyMT-Safe
 

標準規格

POSIX.1-2008.  

歴史

POSIX.1-2001, 4.3BSD.  

警告

Up to glibc 2.1.1, the type of the loc argument was off_t. POSIX.1-2001 specifies long, and this is the type used since glibc 2.1.2. See telldir(3) for information on why you should be careful in making any assumptions about the value in this argument.  

関連項目

lseek(2), closedir(3), opendir(3), readdir(3), rewinddir(3), scandir(3), telldir(3)


 

Index

名前
ライブラリ
書式
説明
返り値
属性
標準規格
歴史
警告
関連項目

This document was created by man2html, using the manual pages.