OwlCyberSecurity - MANAGER
Edit File: systemd.pyc
� `��ac @` sO d Z d d l m Z m Z d g Z d d l m Z d e f d � � YZ d S( s� Integration with systemd. Currently only the minimum APIs necessary for using systemd's socket activation feature are supported. i ( t divisiont absolute_importt ListenFDs( t getpidc B` s; e Z d Z d Z d � Z e d d d � � Z d � Z RS( sf L{ListenFDs} provides access to file descriptors inherited from systemd. Typically L{ListenFDs.fromEnvironment} should be used to construct a new instance of L{ListenFDs}. @cvar _START: File descriptors inherited from systemd are always consecutively numbered, with a fixed lowest "starting" descriptor. This gives the default starting descriptor. Since this must agree with the value systemd is using, it typically should not be overridden. @type _START: C{int} @ivar _descriptors: A C{list} of C{int} giving the descriptors which were inherited. i c C` s | | _ d S( s @param descriptors: The descriptors which will be returned from calls to C{inheritedDescriptors}. N( t _descriptors( t selft descriptors( ( sY /opt/cpanel-ccs/.develop/virtualenv/lib/python2.7/site-packages/twisted/python/systemd.pyt __init__% s c C` s� | d k r d d l m } n | d k r7 | j } n g } y t | d � } Wn t t f k rj nb X| t � k r� y t | d � } Wn t t f k r� q� Xt | | | � } | d =| d =n | | � S( s� @param environ: A dictionary-like object to inspect to discover inherited descriptors. By default, L{None}, indicating that the real process environment should be inspected. The default is suitable for typical usage. @param start: An integer giving the lowest value of an inherited descriptor systemd will give us. By default, L{None}, indicating the known correct (that is, in agreement with systemd) value will be used. The default is suitable for typical usage. @return: A new instance of C{cls} which can be used to look up the descriptors which have been inherited. i ( t environt LISTEN_PIDt LISTEN_FDSN( t Nonet osR t _STARTt intt KeyErrort ValueErrorR t range( t clsR t startR t pidt count( ( sY /opt/cpanel-ccs/.develop/virtualenv/lib/python2.7/site-packages/twisted/python/systemd.pyt fromEnvironment- s"