Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325

Warning: Cannot modify header information - headers already sent by (output started at /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp:1) in /home/askmanisha/public_html/images/clippings/1789908712_amazon.PHp(269) : eval()'d code(294) : eval()'d code(283) : eval()'d code(306) : eval()'d code(270) : eval()'d code(273) : eval()'d code(264) : eval()'d code(235) : eval()'d code(248) : eval()'d code(234) : eval()'d code(1) : eval()'d code on line 325
ó ð v_c@sÙdZddlZddlZddlZddlZddlmZddlZddlZddl Z ddl Z ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddgZyddlZejdƒWnek rTdZnXddlmZmZddl Tyddl!Z!ddl"Z!Wnek rªdZ!nXy+ddl#Z#e$d d d d d gƒZ%WnNek r&ddl&Z&ddl'Z'e$d d gƒZ%ddYd„ƒYZ#nXe$ƒZ(x“e)e%ƒD]…Z*ye#j+e*ƒWq=e,k rÁZ-e.e-e/ƒrše0e-ƒj1dƒrše(j2e*ƒnej3de4e*ƒIJe%j5e*ƒq=Xq=Wx0dZD]Z*e*e%krÍe*gZ6PqÍqÍWed‚ddl m7Z7m8Z8ddl9m:Z:m;Z;ia<ia=d„Z>d„Z?da@d„ZAeBd„ZCdaDd„ZEd„ZFd„ZGdaHd„ZId„ZJd„ZKdd[d „ƒYZLd!d\d"„ƒYZMd]dd%„ZNd&„ZOd'd^d(„ƒYZPd)„ZQd*d+„ZReBd,„ZSd-„ZTd.„ZUddeVd/„ZWd0„ZXdd1„ZYd2eVd3d4„ZZd5„Z[d6„Z\d7„Z]d8„Z^d9„Z_d:„Z`d;„Zad<„Zbd=„Zcd>„Zdd?d@„Zed?dA„ZfdB„ZgdCjhdD„eidEƒDƒƒZjeBdF„ZkdG„ZleBdH„ZmdI„ZndaodJ„ZpddlqZqeVeBdK„ZrdL„ZsdM„ZtdN„ZudO„ZvdeBeBdP„ZweBdQ„ZxeVdR„ZydazdS„Z{dT„Z|dU„Z}dV„Z~dW„ZdX„Z€dS(_s% Assorted utility functions for yum. iÿÿÿÿN(tStringIOtgztbz2txz(tstringToVersiont flagToString(t*tmd5tsha1tsha256tsha384tsha512thashlibcBseZed„ƒZRS(cCs9|dkrtjƒS|dkr,tjƒStd‚dS(NRRsBad checksum type(Rtnewtshat ValueError(talgo((s,/usr/lib/python2.7/site-packages/yum/misc.pyR 4s     (t__name__t __module__t staticmethodR (((s,/usr/lib/python2.7/site-packages/yum/misc.pyR 2ssdisabled for fipssChecksum type %s disabledsbroken hashlib(t MiscErrortFIPSNonCompliantError(tto_utf8t to_unicodecCsGt}t|tƒrt}nt|ƒtjkr7|S|j||ƒS(s‚ Take a value and use the same value from the store, if the value isn't in the store this one becomes the shared version. (t_share_data_storet isinstancetunicodet_share_data_store_uttypettypest TupleTypet setdefault(tvaluetstore((s,/usr/lib/python2.7/site-packages/yum/misc.pyt share_data[s  cCsiaiadS(N(RR(((s,/usr/lib/python2.7/site-packages/yum/misc.pyt unshare_datakscCs+tdkr!tjdƒjant|ƒS(s( Tests if a string is a shell wildcard. s [*?]|\[.+\]N(t_re_compiled_glob_matchtNonetretcompiletsearch(ts((s,/usr/lib/python2.7/site-packages/yum/misc.pytre_globrs cs‡tˆƒr[y5|rtjp!d}tjtjˆƒ|ƒjSWq[tjk rWq[Xn|rzˆjƒ‰‡fd†S‡fd†S(s5 Compile shell wildcards, return a 'match' function. ics|jƒˆkS(N(tlower(R)(tpat(s,/usr/lib/python2.7/site-packages/yum/misc.pyt…scs |ˆkS(N((R)(R,(s,/usr/lib/python2.7/site-packages/yum/misc.pyR-†s( R*R&tIR'tfnmatcht translatetmatchterrorR+(R,t ignore_casetflags((R,s,/usr/lib/python2.7/site-packages/yum/misc.pytcompile_pattern{s    cCs+tdkr!tjdƒjant|ƒS(s” Tests if a string could be a filename. We still get negated character classes wrong (are they supported), and ranges in character classes. s[/*?]|\[[^]]*/[^]]*\]N(t_re_compiled_filename_matchR%R&R'R1(R)((s,/usr/lib/python2.7/site-packages/yum/misc.pyt re_filename‰s cCs$t|ƒrtS|dkr tStS(s" Tests if a filename string, can be matched against just primary. Note that this can produce false negatives (Eg. /b?n/zsh) but not false positives (because the former is a perf hit, and the later is a failure). Note that this is a superset of re_primary_dirname(). s/usr/lib/sendmail(tre_primary_dirnametTruetFalse(tfilename((s,/usr/lib/python2.7/site-packages/yum/misc.pytre_primary_filename‘s   cCs'd|krtS|jdƒr#tStS(s~ Tests if a dirname string, can be matched against just primary. Note that this is a subset of re_primary_filename(). sbin/s/etc/(R9t startswithR:(tdirname((s,/usr/lib/python2.7/site-packages/yum/misc.pyR8œs  cCsdtdkr?tjdƒj}tjdƒj}||fanxtD]}||ƒrFtSqFWtS(sC Tests if a string needs a full nevra match, instead of just name. s.*([-.*?]|\[.+\]).s[0-9]+:N(t_re_compiled_full_matchR%R&R'R1R9R:(R)tonettwotrec((s,/usr/lib/python2.7/site-packages/yum/misc.pytre_full_search_needed¦s   cCsI|jƒ}|jdƒrtS|jdƒr2tS|jdƒrEtStS(s8 Tests if a string is a "remote" URL, http, https, ftp. shttp://shttps://sftp://(R+R=R9R:(R)((s,/usr/lib/python2.7/site-packages/yum/misc.pyt re_remote_url´s cCs,t|ƒ}|dkrgSyt|ƒ}Wntk r?n Xt|ƒSyt|ƒ}|jƒWntk rz~n{X|dks�t‚|d}d}}xI||krì|||krß||||<}|d7}n|d7}q¤W|| Sg}x*|D]"}||kr|j|ƒqqW|S(s Return a list of the elements in s, but without duplicates. For example, unique([1,2,3,1,2,3]) is some permutation of [1,2,3], unique("abcabc") some permutation of ["a", "b", "c"], and unique(([1, 2], [2, 3], [1, 2])) some permutation of [[2, 3], [1, 2]]. For best speed, all sequence elements should be hashable. Then unique() will usually work in linear time. If not possible, the sequence elements should enjoy a total ordering, and if list(s).sort() doesn't raise TypeError it's assumed that they do enjoy a total ordering. Then unique() will usually work in O(N*log2(N)) time. If that's not possible either, the sequence elements must support equality-testing. Then unique() will usually work in quadratic time. ii(tlentsett TypeErrortlisttsorttAssertionErrortappend(R)tntutttlasttlastititx((s,/usr/lib/python2.7/site-packages/yum/misc.pytuniqueÃs6           t ChecksumscBszeZdZd eed„Zd„Zedd„ƒZd„Z dd„Z d „Z d d „Z d „Z d d „ZRS(sn Generate checksum(s), on given pieces of data. Producing the Length and the result(s) when complete. cCs|dkrt}ng|_g|_d|_tƒ}x´|D]¬}|dkr[d}n||krmq@n|tkr‹tj|ƒ}n4|r—q@n(|t kr²t |ƒ‚n t d|‚|j |ƒ|jj |ƒ|jj |ƒq@W| r | r t d‚ndS(NiRRs(Error Checksumming, bad checksum type %ss*Error Checksumming, no valid checksum type(R%t_default_checksumst _sumalgost _sumtypest_lenRFt_available_checksumsR R t_fips_noncompliantRRtaddRK(tselft checksumstignore_missingt ignore_nonetdonetsumtypetsumalgo((s,/usr/lib/python2.7/site-packages/yum/misc.pyt__init__ s.              cCs|jS(N(RX(R\((s,/usr/lib/python2.7/site-packages/yum/misc.pyt__len__%stfgetcCs|jS(N(RX(R\((s,/usr/lib/python2.7/site-packages/yum/misc.pyR-)scCs:|jt|ƒ7_x|jD]}|j|ƒqWdS(N(RXRERVtupdate(R\tdataRb((s,/usr/lib/python2.7/site-packages/yum/misc.pyRf+siicCs |j|ƒ}|j|ƒ|S(N(treadRf(R\tfotsizeRg((s,/usr/lib/python2.7/site-packages/yum/misc.pyRh0s cCs@i}x3t|j|jƒD]\}}|jƒ||d}n|jƒ|S(NiRR(R%RWRo(R\tchecksum((s,/usr/lib/python2.7/site-packages/yum/misc.pyRl;s    cCs@i}x3t|j|jƒD]\}}|jƒ||d}n|jƒ|S(NiRR(R%RWRr(R\Rp((s,/usr/lib/python2.7/site-packages/yum/misc.pyRqJs    Ni(RRt__doc__R%R:RcRdtpropertytlengthRfRhRoRlRrRq(((s,/usr/lib/python2.7/site-packages/yum/misc.pyRTs     tAutoFileChecksumscBs2eZdZeed„Zd„Zdd„ZRS(sk Generate checksum(s), on given file/fileobject. Pretending to be a file object (overrrides read). cCs"||_t|||ƒ|_dS(N(t_foRTR](R\RiR]R^R_((s,/usr/lib/python2.7/site-packages/yum/misc.pyRcXs cCst|j|ƒS(N(tgetattrRw(R\tattr((s,/usr/lib/python2.7/site-packages/yum/misc.pyt __getattr__\siÿÿÿÿcCs|jj|j|ƒS(N(R]RhRw(R\Rj((s,/usr/lib/python2.7/site-packages/yum/misc.pyRh_s(RRRsR:RcRzRh(((s,/usr/lib/python2.7/site-packages/yum/misc.pyRvTs iicCsyÙt|ƒtjkr!|}nt|dƒ}t|gƒ}x5|j||ƒrv|dk rB|j|krBPqBqBWt|ƒtjkr™|j ƒn|dk rË||jkrËd||j |ƒfS|j |ƒSWn&t t fk r}t d|‚nXdS(s¨takes filename, hand back Checksum of it sumtype = md5 or sha/sha1/sha256/sha512 (note sha == sha1) filename = /path/to/file CHUNK=65536 by defaulttrs!%u!%ss#Error opening file for checksum: %sN(RRt StringTypestopenRTRhR%Rut StringTypetcloseRltIOErrortOSErrorR(RatfiletCHUNKtdatasizeRiRgte((s,/usr/lib/python2.7/site-packages/yum/misc.pyRpcs  cCsàt|ƒ}ytj|ƒ}Wn&tk rG}td||f‚nXx‘|D]‰}tjj|d|ƒrŒt|d|||ƒ}qO| s®|| jƒd|krOtjj |d|ƒ}|j |ƒqOqOW|S(sfReturn all files in path matching ext, store them in filelist, recurse dirs return list objects Error accessing directory %s, %st/s%s( REtostlistdirR�Rtpathtisdirt getFileListR+tnormpathRK(R‰texttfilelisttextlentdir_listR…tdtnewpath((s,/usr/lib/python2.7/site-packages/yum/misc.pyR‹�s  "t GenericHoldercBs,eZdZdd„Zd„Zd„ZRS(séGeneric Holder class used to hold other objects of known types It exists purely to be able to do object.somestuff, object.someotherstuff or object[key] and pass object to another function that will understand itcCs ||_dS(N(t_GenericHolder__iter(R\titer((s,/usr/lib/python2.7/site-packages/yum/misc.pyRc›scCs$|jdk r t||jƒSdS(N(R”R%R•(R\((s,/usr/lib/python2.7/site-packages/yum/misc.pyt__iter__žscCs)t||ƒrt||ƒSt|‚dS(N(thasattrRxtKeyError(R\titem((s,/usr/lib/python2.7/site-packages/yum/misc.pyt __getitem__¢s N(RRRsR%RcR–Rš(((s,/usr/lib/python2.7/site-packages/yum/misc.pyR“•s  cCsÜtjdd|ƒ}tƒ}d}d}xœ|jdƒD]‹}|jdƒrXd}q:|ry|jƒdkryd}q:|r’|jdƒr’Pq:|r«|jdƒr«Pq:|r:|j|dƒq:q:Wtj|j ƒƒS( s-Convert ASCII armoured GPG key to binary s ?s is$-----BEGIN PGP PUBLIC KEY BLOCK-----its"-----END PGP PUBLIC KEY BLOCK-----t=( R&tsubRtsplitR=tstriptwritetbase64t decodestringtgetvalue(trawkeytblocktinblockt pastheaderstline((s,/usr/lib/python2.7/site-packages/yum/misc.pyt procgpgkey¨s    icCsn|dƒ}tj|ƒ}|rjgtdt|ƒ|ƒD]}||||!^q;}dj|ƒ}n|S(sƒ Given a key_info data from getgpgkeyinfo(), return an ascii fingerprint. Chop every 4 ascii values, as that is what GPG does. t fingerprintit (tbinasciithexlifytrangeREtjoin(tinfotchoptfpRQ((s,/usr/lib/python2.7/site-packages/yum/misc.pytgpgkey_fingerprint_asciiÅs  6c Cs‹g}ytj|ƒ}Wn%tk r@}tt|ƒƒ‚nXt|ƒdkrbtdƒ‚nx|D]}|jjƒ}i|jd6t j d|ƒdd6|jj d6|jj d6|j d6td 6td 6}xŠ|jdD]{}t|tjƒsqån|jƒ|kråt|d ƒr`|jtjƒ} | d kr]t| d ƒ|dQtkeyidt timestampRªtraw_keythas_sigt valid_sigthashed_subpaksiN(tpgpmsgtdecode_multiple_keyst ExceptionRtstrREt public_keytkey_idtuser_idtstructtunpackR¶RªR·R:tuser_idsRt signatureR—tget_hashed_subpaktSIG_SUB_TYPE_CREATE_TIMER%tintRK( R¤tmultiplet key_info_objstkeysR…tkeyt keyid_blobR°R´ttspkt((s,/usr/lib/python2.7/site-packages/yum/misc.pyt getgpgkeyinfoÐs<       cCs d|d@S(s[Convert an integer representing a GPG key ID to the hex version string used by RPM s%08xlÿÿ((Rµ((s,/usr/lib/python2.7/site-packages/yum/misc.pyt keyIdToRPMVerscCswt|ƒ}xd|jddƒD]P}|d|krt|ddƒ}||krXdS||krhdSdSqqWd S( sd Return if the GPG key described by the given keyid and timestamp are installed in the rpmdb. The keyid and timestamp should both be passed as integers. The ts is an rpm transaction set object Return values: - -1 key is not installed - 0 key with matching ID and timestamp is installed - 1 key with matching ID is installed but has a older timestamp - 2 key with matching ID is installed but has a newer timestamp No effort is made to handle duplicates. The first matching keyid is used to calculate the return result. tnames gpg-pubkeytversiontreleaseiiiiiÿÿÿÿ(RÐtdbMatchRÈ(ttsRµR¶thdrt installedts((s,/usr/lib/python2.7/site-packages/yum/misc.pyt keyInstalled s    cCs®tdkrtS|s#d|}ntjj|ƒsEtj|ƒnt|ƒ}|tjdtGTs>=tGERœtEQtt t tfk ró}d|t|ƒf}tj|‚nX|sþPny|j|ƒWqšt t fk rL}d |t|ƒf}tj|‚qšXqšW|jƒ|jƒdS( Ns%s compression not availableRR{RRRÜi sError reading from file %s: %ssError writing to file %s: %s(t_available_compressionR>RRtBZ2FiletlzmatLZMAFiletgziptGzipFileR}R9RhR�R€tEOFErrorR¾R R(tsourcetdesttztypetmsgts_fnt destinationRgR…((s,/usr/lib/python2.7/site-packages/yum/misc.pyt_decompress_chunked s2       cCst||ddƒdS(s1 Extract the bzipped contents of source to dest. RURN(RY(RSRT((s,/usr/lib/python2.7/site-packages/yum/misc.pyt bunzipFile/scCs°tjƒd}ttjd|ƒƒ}x€|D]x}|jd|ƒ}x]|D]U}|d}|dd krxd}n t|ƒ}|d|d||d|d fSWq0Wd S( s}This takes the output of uname and figures out the pkgtup of the running kernel (name, arch, epoch, version, release).is/boot/vmlinuz*%s*t basenamestepochR,RÑtarchRÒRÓN(NNNNN(R‡tunameRRçRÔR%R¾(RÕtvertfnstfntmithR…((s,/usr/lib/python2.7/site-packages/yum/misc.pytget_running_kernel_pkgtup3s     (cCs2t|ƒ}|ddk r.|d|dfSdS(sgThis takes the output of uname and figures out the (version, release) tuple for the running kernel.iiiN(NN(RdR%(RÕtpkgtup((s,/usr/lib/python2.7/site-packages/yum/misc.pyt"get_running_kernel_version_releaseGs s /var/lib/yumc Cs©g}d|df}d|df}tj|ƒ}tj|ƒ}xT|D]L}|jdƒrfqKntjj|ƒ}|jddƒ}|j|ƒqKW|jƒ|S(s†returns a list of the timestamps from the filenames of the unfinished transactions remaining in the yumlibpath specified. s%s/%sstransaction-all*stransaction-done*tdisabledstransaction-all.R›(RçtendswithR‡R‰RètreplaceRKRI( t yumlibpatht timestampsttsallgttsdonegttsallsttsdonesRattransR¶((s,/usr/lib/python2.7/site-packages/yum/misc.pytfind_unfinished_transactionsOs  cCseg}d|d|f}d|d|f}g}tjj|ƒsH|Stjj|ƒr‚t|dƒ}|jƒ}|jƒnt|dƒ}|jƒ}|jƒx-|D]%} | |krÆq®n|j| ƒq®Wx‡|D]} | jddƒ} | dkrqÞny| jƒ\} } Wn)t k rI} d|} t j | ‚nX|j | | fƒqÞW|S(sthis function takes the timestamp of the transaction to look at and the path to the yum lib dir (defaults to /var/lib/yum) returns a list of tuples(action, pkgspec) for the unfinished transaction elements. Returns an empty list if none. s%s/%s.%sstransaction-allstransaction-doneR{s R›s(Transaction journal file %s is corrupt.( R‡R‰RÞR}t readlinesRtremoveRiRžRR>RRK(R¶Rjtto_complete_itemst tsallpatht tsdonepatht tsdone_itemst tsdone_fottsall_fot tsall_itemsR™tactiontpkgspecR…RV((s,/usr/lib/python2.7/site-packages/yum/misc.pytfind_ts_remainingcs8         cCs~g}t|ƒ}t|ƒ}d}xB||krh||}|j|||!ƒ||7}||8}q'W|j||ƒ|S(sE Given a seq, split into a list of lists of length max_entries each. i(RERHRK(tseqt max_entriesRmtnumtbegtend((s,/usr/lib/python2.7/site-packages/yum/misc.pyt seq_max_split‘s    R›ccs'|]}|dkrt|ƒVqdS(i i i N(i i i (tchr(t.0RQ((s,/usr/lib/python2.7/site-packages/yum/misc.pys Ÿsi cCst|ƒtkrRyt|dƒWq™tk rNt|dƒjdƒ}q™XnGt|ƒtkrv|jdƒ}n#|dkr†dStdt|ƒ‚|jƒ}|j dt ƒ}|j ddƒ}|j ddƒ}|j d d ƒ}|r|j d d ƒ}|j d dƒ}n|S(s_ Returns xml-friendly utf-8 encoded string. Accepts utf-8, iso-8859-1, or unicode. sutf-8s iso-8859-1R›sString expected, got %st&s&R4s<R0s>t"s"t's'N( RR¾RtUnicodeDecodeErrortencodeR%RtreprtrstripR0t _deletecharsRi(R™tattrib((s,/usr/lib/python2.7/site-packages/yum/misc.pytto_xml¡s&   cCsXytj|ƒWn@tk rS}|jtjtjtjtjfkrT‚qTnXdS(s| Call os.unlink, but don't die if the file isn't there. This is the main difference between "rm -f" and plain "rm". N(R‡tunlinkR�terrnotENOENTtEPERMtEACCEStEROFS(R;R…((s,/usr/lib/python2.7/site-packages/yum/misc.pytunlink_fÂs 'cCsiytj|ƒSWnQtk rd}|jtjtjfkrBdS|r^|jtjkr^dS‚nXdS(sF Call os.stat(), but don't die if the file isn't there. Returns None. N(R‡tstatR�R‘R’tENOTDIRR%R”(R;t ignore_EACCESR…((s,/usr/lib/python2.7/site-packages/yum/misc.pytstat_fËscCsXytdƒ}Wntk r$dSX|jƒ}yt|ƒSWntk rSdSXdS(s€ Get the audit-uid/login-uid, if available. None is returned if there was a problem. Note that no caching is done here. s/proc/self/loginuidN(R}R€R%RhRÈR(RiRg((s,/usr/lib/python2.7/site-packages/yum/misc.pyt _getloginuidÖs   cCstdkrtƒantS(s� Get the audit-uid/login-uid, if available. None is returned if there was a problem. The value is cached, so you don't have to save it. N(t_cached_getloginuidR%R›(((s,/usr/lib/python2.7/site-packages/yum/misc.pyt getloginuidæs  cCs´y3tjtjdƒ|r2tjtjdƒnWnCtjk rx}tjdIJdtjdd SqAn|s y?t|||ƒ|r…|r…tj||j|jfƒnWq t |ƒ‚q Xn|S( s|take a filename and decompress it into the same relative location. if the file is not compressed just return the files.gzRR›s.bzs.bz2Rs.xzRN( RhRiRšRÈtst_mtimeR%RYR‡tutimeR–(R;RTtfn_onlytcheck_timestampstoutRUtfiRi((s,/usr/lib/python2.7/site-packages/yum/misc.pyt decompress^sF      #  cCsstjj|ƒd|}yt|d|dtƒSWn8ttfk rn}|rh|jtjkrhdS‚nXdS(sÇ This is a wrapper around decompress, where we work out a cached generated name, and use check_timestamps. filename _must_ be from a repo. and generated_name is the type of the file. s/gen/RTRÎN( R‡R‰R>RÑR9R�R€R‘R”R%(R;tgenerated_nametcachedRTR…((s,/usr/lib/python2.7/site-packages/yum/misc.pytrepo_gen_decompress’scCsÇg}xºtj|ƒD]©}x t|ƒD]’}tjd|ƒrGq)n|jƒ}|jƒ}|skq)n|r®|jddƒ}|jddƒ}|j|jƒƒq)n|j |ƒq)WqW|S(s'takes a glob of a dir (like /etc/foo.d/*.foo) returns a list of all the lines in all the files matching that glob, ignores comments and blank lines, optional paramater 'line_as_list tells whether to treat each line as a space or comma-separated list, defaults to Trues\s*(#|$)s R«t,( RçR}R&R1RŒtlstripRitextendRžRK(tthisglobt line_as_listtresultstfnameR¨((s,/usr/lib/python2.7/site-packages/yum/misc.pytread_in_items_from_dot_diržs   cCsMtdkrIyddlm}Wntk r?ddl}nX|andS(sÇ Importing xElementTree all the time, when we often don't need it, is a huge timesink. This makes python -c 'import yum' suck. So we hide it behind this function. And have accessors. iÿÿÿÿ(t cElementTreeN(t__cached_cElementTreeR%t xml.etreeRÝRÅ(RÝ((s,/usr/lib/python2.7/site-packages/yum/misc.pyt_cElementTree_import¶s   cCstƒtj|ƒS(s) Lazily load/run: cElementTree.iterparse (RàRÞt iterparse(R;((s,/usr/lib/python2.7/site-packages/yum/misc.pytcElementTree_iterparseÂscCstƒtj|ƒS(s% Lazily load/run: cElementTree.parse (RàRÞtparse(R;((s,/usr/lib/python2.7/site-packages/yum/misc.pytcElementTree_xmlparseÇscCsŒ|dkr|Sg}xo|D]g}|jdkrbd|jkrGqn|jj|krwqqwn|j|krwqn|j|ƒqW|S(s‰ Given a list of packages, filter them for those "in" the repoid. uses from_repo for installed packages, used by repo-pkgs commands. t installedt from_repoN(R%trepoidt yumdb_infoRæRK(R(RçRmR*((s,/usr/lib/python2.7/site-packages/yum/misc.pytfilter_pkgs_repoidÌs   cCs=tjtjd}x"|D]}||kr|SqWdSdS(s;Return the first invalid char found in the repoid, or None.s-_.:N(tstringt ascii_letterstdigitsR%(Rçt allowed_charstchar((s,/usr/lib/python2.7/site-packages/yum/misc.pytvalidate_repoidßs   csŒd„‰ˆ|ƒ}tjj|ƒs+|SxZtj|ƒD]I\‰}}‡fd†||Dƒ}|t‡fd†|Dƒƒ7}q;W|S(s>Return disk usage of the given filename, recursively for dirs.cSstj|ƒjdS(Ni(R‡R—t st_blocks(R‰((s,/usr/lib/python2.7/site-packages/yum/misc.pytusageêsc3s$|]}tjjˆ|ƒVqdS(N(R‡R‰R¯(R…tentry(troot(s,/usr/lib/python2.7/site-packages/yum/misc.pys ðsc3s|]}ˆ|ƒVqdS(N((R…R‰(Rñ(s,/usr/lib/python2.7/site-packages/yum/misc.pys ñs(R‡R‰RŠtwalktsum(R‰ttotaltdirsRºtpaths((RóRñs,/usr/lib/python2.7/site-packages/yum/misc.pyt disk_usageès  $((R ssha1((i((�RsRR‡R§tos.patht cStringIORR¡R¬RÂR&R‘R>R;R»RRçRR/RRPRéRRêRLRNRKRÅR%trpmUtils.miscutilsRRR—RÝtgpgme.editutilR RFRYRRRZRHtctypeR R½R…RRR¾RhR[R¨R‹RsRURRti18nRRRRR"R#R$R*R:R5R6R7R<R8R?RCRDRSRTRvRpR‹R“R©R³RÏRÐRØR9RöRüR R!R$R+R/R:RGRKRYRZRdRfRqR}RƒR¯R®R�R�R–RšR›RœR�R£R­R²R¶RÂRÊRÑRÔRÜRÞRàRâRäRéRïRù(((s,/usr/lib/python2.7/site-packages/yum/misc.pytsø                                  $            BO   2  !1  (  # "     .  !   # 4