tzh
2024-08-22 c7d0944258c7d0943aa7b2211498fd612971ce27
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
]\¬Qc@sydddgZddlZddlZddlZddlZddlZddlZddlZddlZddl    m
Z
m Z ddl m Z mZmZmZddlmZmZdZd    ZejƒZd
Zd
gZeed ƒr    d Zed g7Znejd kr.d Zed g7Zned„Zd„Zd„Zd„Zde fd„ƒYZ!ddd„Z#ejd kr˜e$d„Z%nddlm&Z&e$d„Z%de fd„ƒYZ'd„Z(ejd krde fd„ƒYZ)d„Z*ndZ+dZ,dZ-d Z.d!„Z/d"„Z0d#e fd$„ƒYZ1d%„Z2d&„Z3d'e!fd(„ƒYZ4d)„Z5dS(*tClienttListenertPipeiÿÿÿÿN(tcurrent_processtAuthenticationError(t get_temp_dirtFinalizet    sub_debugtdebug(t    duplicatetclosei g4@tAF_INETtAF_UNIXtwin32tAF_PIPEcCstjƒ|S(N(ttime(ttimeout((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt _init_timeoutIscCstjƒ|kS(N(R(tt((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt_check_timeoutLscCsw|dkrd S|dkr5tjdddtƒƒS|dkrgtjdd    tjƒtjƒfƒStd
ƒ‚d S( s?
    Return an arbitrary free address for the given family
    R t    localhostiR tprefixs    listener-tdirRs\\.\pipe\pyc-%d-%d-sunrecognized familyN(Ri(ttempfiletmktempRtostgetpidt _mmap_countertnextt
ValueError(tfamily((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pytarbitrary_addressSs    cCset|ƒtkrdSt|ƒtkr;|jdƒr;dSt|ƒtkrQdStd|ƒ‚dS(s]
    Return the types of the address
 
    This can be 'AF_INET', 'AF_UNIX', or 'AF_PIPE'
    R s\\RR saddress type of %r unrecognizedN(ttypettupletstrt
startswithR(taddress((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt address_typebs!cBsSeZdZddddd„Zd„Zd„Zed„ƒZed„ƒZ    RS(s•
    Returns a listener object.
 
    This is a wrapper for a bound socket which is 'listening' for
    connections, or for a Windows named pipe.
    icCs›|p|rt|ƒpt}|p-t|ƒ}|dkrQt||ƒ|_nt|||ƒ|_|dk    rŽt|tƒ rŽt    d‚n||_
dS(NRsauthkey should be a byte string( R%tdefault_familyRt PipeListenert    _listenertSocketListenertNonet
isinstancetbytest    TypeErrort_authkey(tselfR$Rtbacklogtauthkey((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt__init__|s  cCs?|jjƒ}|jr;t||jƒt||jƒn|S(sz
        Accept a connection on the bound socket or named pipe of `self`.
 
        Returns a `Connection` object.
        (R(tacceptR.tdeliver_challengetanswer_challenge(R/tc((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR3‹s
    cCs |jjƒS(sA
        Close the bound socket or named pipe of `self`.
        (R(R
(R/((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR
—scCs
|jjS(N(R(t_address(R/((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt<lambda>scCs
|jjS(N(R(t_last_accepted(R/((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR8žsN(
t__name__t
__module__t__doc__R*R2R3R
tpropertyR$t last_accepted(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyRus         cCsŽ|pt|ƒ}|dkr-t|ƒ}n t|ƒ}|dk    rat|tƒ ratd‚n|dk    rŠt||ƒt||ƒn|S(s=
    Returns a connection to the address of a `Listener`
    Rsauthkey should be a byte stringN(    R%t
PipeClientt SocketClientR*R+R,R-R5R4(R$RR1R6((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR¡s     cCsË|r…tjƒ\}}|jtƒ|jtƒtjtj|jƒƒƒ}tjtj|jƒƒƒ}|j    ƒ|j    ƒn<tj
ƒ\}}tj|dt ƒ}tj|dt ƒ}||fS(sL
        Returns pair of connection objects at either end of a pipe
        twritabletreadable( tsockett
socketpairt setblockingtTruet_multiprocessingt
ConnectionRtduptfilenoR
tpipetFalse(tduplexts1ts2tc1tc2tfd1tfd2((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR·s  
 (R c    CsUtdƒ}|r;tj}tjtjB}tt}}ntj}tj}dt}}tj||tjtj    Btj
Bd||tj tj ƒ}tj ||dtj tjdtj ƒ}tj|tj    ddƒytj|tj ƒWn/tk
r }|jdtjkr!‚q!nXtj|d|ƒ}    tj|d|ƒ}
|    |
fS(sL
        Returns pair of connection objects at either end of a pipe
        RiiRARBN(RR tPIPE_ACCESS_DUPLEXt GENERIC_READt GENERIC_WRITEtBUFSIZEtPIPE_ACCESS_INBOUNDtCreateNamedPipetPIPE_TYPE_MESSAGEtPIPE_READMODE_MESSAGEt    PIPE_WAITtNMPWAIT_WAIT_FOREVERtNULLt
CreateFilet OPEN_EXISTINGtSetNamedPipeHandleStateR*tConnectNamedPipet WindowsErrortargstERROR_PIPE_CONNECTEDRGtPipeConnection( RMR$topenmodetaccesstobsizetibsizeth1th2teRPRQ((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyRÍs2               $
R)cBs,eZdZdd„Zd„Zd„ZRS(sO
    Representation of a socket which is bound to an address and listening
    icCsötjtt|ƒƒ|_yb|jjtjtjdƒ|jjtƒ|jj|ƒ|jj    |ƒ|jj
ƒ|_ Wn$tj k
r£|jj ƒ‚nX||_d|_|dkrét|tjd|fddƒ|_n    d|_dS(NiR Rdt exitpriorityi(RCtgetattrt_sockett
setsockoptt
SOL_SOCKETt SO_REUSEADDRRERFtbindtlistent getsocknameR7terrorR
t_familyR*R9RRtunlinkt_unlink(R/R$RR0((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR2ûs           $cCsT|jjƒ\}|_|jtƒt|jƒƒ}tj|ƒ}|j    ƒ|S(N(
RpR3R9RERFR    RJRGRHR
(R/tstfdtconn((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR3s  
cCs-|jjƒ|jdk    r)|jƒndS(N(RpR
RzR*(R/((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR
s (R:R;R<R2R3R
(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR)÷s     cCsßt|ƒ}tjtt|ƒƒ}|jtƒtƒ}xsy|j|ƒWnXtjk
r¨}|jdt    j
ks…t |ƒr˜t d|ƒ‚nt jdƒq=XPq=‚t|jƒƒ}tj|ƒ}|jƒ|S(sO
    Return a connection object connected to the socket given by `address`
    isfailed to connect to address %sg{®Gáz„?(R%RCRoRERFRtconnectRwRdterrnot ECONNREFUSEDRRRtsleepR    RJRGRHR
(R$RR{RRmR|R}((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR@s$      " 
R'cBs2eZdZdd„Zd„Zed„ƒZRS(s0
        Representation of a named pipe
        c    Cs ||_tj|tjtjtjBtjBtjtttj    tj
ƒ}|g|_ d|_ td|jƒt|tjd|j |jfddƒ|_dS(Ns listener created with address=%rRdRni(R7R RYRTRZR[R\tPIPE_UNLIMITED_INSTANCESRWR]R^t _handle_queueR*R9RRR't_finalize_pipe_listenerR
(R/R$R0thandle((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR2Cs                c    CsÅtj|jtjtjtjBtjBtjtttj    tj
ƒ}|j j |ƒ|j j dƒ}ytj|tj
ƒWn8tk
r·}|jdtjtjfkr¸‚q¸nXtj|ƒS(Ni(R RYR7RTRZR[R\R‚RWR]R^RƒtappendtpopRbRcRdRet ERROR_NO_DATARGRf(R/t    newhandleR…Rm((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR3Vs   
cCs,td|ƒx|D]}t|ƒqWdS(Ns closing listener with address=%r(RR
(tqueueR$R…((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR„js  N(R:R;R<R*R2R3t staticmethodR„(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR'?s     cCsÈtƒ}x–yHtj|dƒtj|tjtjBdtjtjdtjƒ}WnDtk
rš}|j    dtj
tj fks‘t |ƒrœ‚qœq XPq ‚tj |tjddƒtj|ƒS(sU
        Return a connection object connected to the pipe given by `address`
        ièiN(RR t WaitNamedPipeR_RURVR^R`RcRdtERROR_SEM_TIMEOUTtERROR_PIPE_BUSYRRaR[R*RGRf(R$RthRm((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR?ps     "
is #CHALLENGE#s    #WELCOME#s    #FAILURE#cCs¡ddl}t|tƒs!t‚tjtƒ}|jt|ƒ|j    ||ƒj
ƒ}|j dƒ}||kr„|jt ƒn|jt ƒtdƒ‚dS(Niÿÿÿÿisdigest received was wrong(thmacR+R,tAssertionErrorRturandomtMESSAGE_LENGTHt
send_bytest    CHALLENGEtnewtdigestt
recv_bytestWELCOMEtFAILURER(t
connectionR1RtmessageR—tresponse((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR4”s   cCs¹ddl}t|tƒs!t‚|jdƒ}|ttƒ tksVtd|ƒ‚|ttƒ}|j||ƒjƒ}|j    |ƒ|jdƒ}|t
krµt dƒ‚ndS(Niÿÿÿÿis message = %rsdigest sent was rejected( RR+R,R‘R˜tlenR•R–R—R”R™R(R›R1RRœR—R((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR5¡s &  tConnectionWrappercBs#eZd„Zd„Zd„ZRS(cCsO||_||_||_x-dD]%}t||ƒ}t|||ƒq"WdS(NRJR
tpollR˜R”(sfilenoscloseR s
recv_bytess
send_bytes(t_connt_dumpst_loadsRotsetattr(R/R}tdumpstloadstattrtobj((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR2²s              cCs#|j|ƒ}|jj|ƒdS(N(R¢R¡R”(R/R¨R{((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pytsend¹scCs|jjƒ}|j|ƒS(N(R¡R˜R£(R/R{((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pytrecv¼s(R:R;R2R©Rª(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyRŸ±s        cCs%tj|fddddƒjdƒS(Nitutf8(t    xmlrpclibR¥R*tencode(R¨((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt
_xml_dumpsÀscCs%tj|jdƒƒ\\}}|S(NR«(R¬R¦tdecode(R{R¨tmethod((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt
_xml_loadsÃs!t XmlListenercBseZd„ZRS(cCs+ddlatj|ƒ}t|ttƒS(Niÿÿÿÿ(R¬RR3RŸR®R±(R/R¨((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR3Ès (R:R;R3(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyR²ÇscOs%ddlatt||ŽttƒS(Niÿÿÿÿ(R¬RŸRR®R±(Rdtkwds((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt    XmlClientÎs (6t__all__RtsysRCRRRt    itertoolsRGtmultiprocessingRRtmultiprocessing.utilRRRRtmultiprocessing.forkingR    R
RWtCONNECTION_TIMEOUTtcountRR&tfamiliesthasattrtplatformRRRR%tobjectRR*RRFRR R)R@R'R?R“R•R™RšR4R5RŸR®R±R²R´(((sb/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/multiprocessing/connection.pyt<module>#s`        "                  , *'    1