コード例 #1
0
 def gids(self):
     with open("/proc/%s/status" % self.pid, 'rb') as f:
         for line in f:
             if line.startswith(b'Gid:'):
                 _, real, effective, saved, fs = line.split()
                 return _common.pgids(int(real), int(effective), int(saved))
         raise NotImplementedError("line not found")
コード例 #2
0
 def gids(self):
     with open("/proc/%s/status" % self.pid, 'rb') as f:
         for line in f:
             if line.startswith(b'Gid:'):
                 _, real, effective, saved, fs = line.split()
                 return _common.pgids(int(real), int(effective), int(saved))
         raise NotImplementedError("line not found")
コード例 #3
0
ファイル: _pslinux.py プロジェクト: ztop/psutil
 def gids(self):
     f = open("/proc/%s/status" % self.pid)
     try:
         for line in f:
             if line.startswith('Gid:'):
                 _, real, effective, saved, fs = line.split()
                 return _common.pgids(int(real), int(effective), int(saved))
         raise NotImplementedError("line not found")
     finally:
         f.close()
コード例 #4
0
 def gids(self):
     f = open("/proc/%s/status" % self.pid, 'rb')
     try:
         GID = b('Gid:')
         for line in f:
             if line.startswith(GID):
                 _, real, effective, saved, fs = line.split()
                 return _common.pgids(int(real), int(effective), int(saved))
         raise NotImplementedError("line not found")
     finally:
         f.close()
コード例 #5
0
ファイル: _psosx.py プロジェクト: mx739150/ambari-app
 def gids(self):
     real, effective, saved = cext.proc_gids(self.pid)
     return _common.pgids(real, effective, saved)
コード例 #6
0
ファイル: _psbsd.py プロジェクト: 2089764/psutil
 def gids(self):
     real, effective, saved = cext.proc_gids(self.pid)
     return _common.pgids(real, effective, saved)
コード例 #7
0
ファイル: _psbsd.py プロジェクト: ztop/psutil
 def gids(self):
     """Return real, effective and saved group ids."""
     real, effective, saved = cext.proc_gids(self.pid)
     return _common.pgids(real, effective, saved)