Man page - llseek(2)

Packages contains this manual

Available languages:

en fr es pl ja ru ro de

Manual

LLSEEK

名 前
書 式
説 明
返 り 値
エ ラ ー
準 拠
注 意
関 連 項 目
こ の 文 書 に つ い て

名 前

_llseek - フ ァ イ ル の 読 み 書 き オ フ セ ッ ト の 位 置 を 変 え る

書 式

#include <sys/types.h>
#include <unistd.h>

int _llseek(unsigned int fd , unsigned long offset_high ,
unsigned long
offset_low , loff_t * result ,
unsigned int
whence );

: こ の シ ス テ ム コ ー ル に は glibc の ラ ッ パ ー 関 数 は 存 在 し な い 。 「 注 意 」 の 節 を 参 照 。

説 明

Note: for information about the llseek (3) library function, see lseek64 (3).

The _llseek () system call repositions the offset of the open file description associated with the file descriptor fd to the value

(offset_high << 32) | offset_low

This new offset is a byte offset relative to the beginning of the file, the current file offset, or the end of the file, depending on whether whence is SEEK_SET , SEEK_CUR , or SEEK_END , respectively.

The new file offset is returned in the argument result . The type loff_t is a 64-bit signed type.

This system call exists on various 32-bit platforms to support seeking to large file offsets.

返 り 値

成 功 し た 場 合 は 、 _llseek () は 0 を 返 す 。 そ う で な れ ば -1 と い う 値 が 返 り 、 エ ラ ー を 示 す errno が 設 定 さ れ る 。

エ ラ ー

EBADF

fd が オ ー プ ン さ れ た フ ァ イ ル デ ィ ス ク リ プ タ ー で な い 。

EFAULT

結 果 を ユ ー ザ ー 空 間 に コ ピ ー す る と き に 問 題 が あ っ た 。

EINVAL

whence が 不 正 で あ る 。

準 拠

こ の 関 数 は Linux 特 有 で あ り 、 移 植 性 の 必 要 な プ ロ グ ラ ム で は 使 用 し て は い け な い 。

注 意

Glibc does not provide a wrapper for this system call. To invoke it directly, use syscall (2). However, you probably want to use the lseek (2) wrapper function instead.

関 連 項 目

lseek (2), open (2), lseek64 (3)

こ の 文 書 に つ い て

こ の man ペ ー ジ は Linux man-pages プ ロ ジ ェ ク ト の リ リ ー ス 5.10 の 一 部 で あ る 。 プ ロ ジ ェ ク ト の 説 明 と バ グ 報 告 に 関 す る 情 報 は https://www.kernel.org/doc/man-pages/ に 書 か れ て い る 。