U:RDoc::AnyMethod[iI"unix_rights:ETI"&Socket::AncillaryData#unix_rights;TF: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"Zreturns the array of IO objects for SCM_RIGHTS control message in UNIX domain socket.;To:RDoc::Markup::BlankLineo; ; [I">The class of the IO objects in the array is IO or Socket.;T@o; ; [I"GThe array is attached to _ancillarydata_ when it is instantiated. ;TI"true option is given.;T@o:RDoc::Markup::Verbatim; [I"7# recvmsg needs :scm_rights=>true for unix_rights ;TI"s1, s2 = UNIXSocket.pair ;TI"Ip s1 #=> # ;TI"[s1.sendmsg "stdin and a socket", 0, nil, Socket::AncillaryData.unix_rights(STDIN, s1) ;TI"2_, _, _, ctl = s2.recvmsg(:scm_rights=>true) ;TI"gp ctl #=> # ;TI"Sp ctl.unix_rights #=> [#, #] ;TI";p File.identical?(STDIN, ctl.unix_rights[0]) #=> true ;TI";p File.identical?(s1, ctl.unix_rights[1]) #=> true ;TI" ;TI"B# If :scm_rights=>true is not given, unix_rights returns nil ;TI"s1, s2 = UNIXSocket.pair ;TI"[s1.sendmsg "stdin and a socket", 0, nil, Socket::AncillaryData.unix_rights(STDIN, s1) ;TI"_, _, _, ctl = s2.recvmsg ;TI"@p ctl #=> # ;TI"p ctl.unix_rights #=> nil;T: @format0: @fileI"ext/socket/ancdata.c;T:0@omit_headings_from_table_of_contents_below0I"6ancillarydata.unix_rights => array-of-IOs or nil ;T0[I"();T@)FI"AncillaryData;TcRDoc::NormalClass00