2件ヒット
[1-2件を表示]
(0.044秒)
検索結果
-
IO
# fcntl(cmd , arg = 0) -> Integer (54658.0) -
IOに対してシステムコール fcntl を実行します。 機能の詳細は fcntl(2) を参照してください。 fcntl(2) が返した整数を返します。
...
IOに対してシステムコール fcntl を実行します。
機能の詳細は fcntl(2) を参照してください。
fcntl(2) が返した整数を返します。
@param cmd IO に対するコマンドを、添付ライブラリ fcntl が提供している定数で指定します。
@param......ます。
@raise Errno::EXXX fcntl の実行に失敗した場合に発生します。
@raise IOError 既に close されている場合に発生します。
//emlist[例][ruby]{
require "fcntl"
IO.write("testfile", "abcde")
# ファイル状態フラグを読み出す
File.open("testfile") do |... -
IO
# close _ on _ exec=(bool) (31.0) -
自身に close-on-exec フラグを設定します。
...2)
@param bool 自身の close-on-exec フラグを true か false で指定します。
f = open("/dev/null")
f.close_on_exec = true
system("cat", "/proc/self/fd/#{f.fileno}") # cat: /proc/self/fd/3: No such file or directory
f.closed? #=> false
@see IO#close_on_exec?...