mò óRÅDc@sKdklZdklZdkTeeƒdƒdefd„ƒYZdS((s demandload(sgettext(t*s os streamclone sys tempfile utilt sshservercBstZd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z d „Z d „Z d „Z d „Z d „Zd„Zd„ZRS(NcCsc||_||_d|_ti|_ti|_ ti t_t i |iƒt i |i ƒdS(N( tuitselftrepotNonetlocktsyststdintfintstdouttfouttstderrtutilt set_binary(RRR((t7/usr/lib/python2.4/site-packages/mercurial/sshserver.pyt__init__s      cCsG|iiƒd }|iƒ\}}|iit|ƒƒ}||fS(Niÿÿÿÿ( RR treadlinetarglinetsplittargtltreadtinttval(RRRRR((RtgetargscCs;|iidt|ƒƒ|ii|ƒ|iiƒdS(Ns%d (RR twritetlentvtflush(RR((Rtrespond!scCs&x|iƒoqWtidƒdS(Ni(Rt serve_oneRtexit(R((Rt serve_forever&s cCs]|iiƒd }|o9t|d|dƒ}|o |ƒqS|idƒn|djS(Niÿÿÿÿtdo_t(RR RtcmdtgetattrRtimplR(RR$R&((RR*s cCs6|iiƒ}|iditt|ƒƒdƒdS(Nt s (RRtheadsthRtjointmapthex(RR)((Rtdo_heads2scCs[dg}|iiddƒo|id|iiƒn|iddi|ƒfƒdS(s)the hello command returns a set of lines describing various interesting things about the server, in an RFC822-like format. Currently the only one defined is "capabilities", which consists of a line in the form: capabilities: space separated list of tokens tunbundletservert uncompresseds stream=%dscapabilities: %s R'N( tcapsRRt configbooltappendRt revlogversionRR*(RR1((Rtdo_hello6s  cCs#|iiƒ|_|idƒdS(s<DEPRECATED - allowing remote client to lock repo is not safeR#N(RRRR(R((Rtdo_lockDscCs5|io|iiƒnd|_|idƒdS(t DEPRECATEDR#N(RRtreleaseRR(R((Rt do_unlockJs   cCsŠ|iƒ\}}tt|idƒƒ}g}x=|ii |ƒD])}|i di tt |ƒƒdƒqCW|idi |ƒƒdS(NR's R#(RRRtnodesR+tbinRtrRtbranchestbR3R*R,R(RR>R<RR:((Rt do_branchesRs'cCs®|iƒ\}}g}|idƒD]}|tt|idƒƒq&~}g}x=|i i |ƒD])}|i ditt|ƒƒdƒqgW|idi|ƒƒdS(NR't-s R#(RRRtpairst_[1]RtpR+R;R<RtbetweenR>R3R*R,R(RRAR>RBRCR<R((Rt do_betweenZs<'cCsg}|iƒ\}}tt|idƒƒ}|ii |dƒ}x7t o/|i dƒ}|pPn|ii|ƒqHW|iiƒdS(NR'tservei(R:RRRtrootsR+R;RRt changegrouptcgtTrueRtdR RR(RRKRIRR:RG((Rtdo_changegroupbscCs[|ip|idƒdSn|idƒ|ii|idƒ}|it|ƒƒdS(R7s not lockedNR#RF(RRRRtaddchangegroupR R<tstr(RR<((Rtdo_addchangegroupps   c s²ˆiƒdiƒ‰‡‡d†}|ƒpˆitdƒƒdSnˆidƒz<tiddƒ\}}t i |dƒ}tˆiiƒƒ}x:|o2|iˆii|ƒƒtˆiiƒƒ}qœWˆidj }|pˆiiƒˆ_nzk|ƒpˆitdƒƒdSnˆidƒ|idƒˆii|d ƒ}ˆit|ƒƒWd|pˆiiƒdˆ_nXWd|iƒt i|ƒXdS( Nics8ttˆiiƒƒ}ˆtdƒgjp ˆ|jS(Ntforce(R+R,RRR(t their_heads(R((RRQ(Rt check_heads~ssunsynced changesR#tprefixs hg-unbundle-swb+iRF(RRRRQRRRt_ttempfiletmkstemptfdttempnametostfdopentfpRR RtcountRRRRt was_lockedRtseekRMR<RNR8tclosetunlink( RR[R\RRRQR]R<RWRX((RRQRt do_unbundle{s@       cCsti|i|iƒdS(N(t streamclonet stream_outRRR (R((Rt do_stream_out¬s(t__name__t __module__RRRR!RR-R5R6R9R?RERLRORaRd(((RR s            1N(t demandloadti18ntgettextRTtnodetglobalstobjectR(RgRRT((Rt?s