code: def kill(self, dwProcessId, bIgnoreExceptions = False):
          
  
          # Keep a reference to the process. We'll need it later.
          try:
              aProcess = self.system.get_process(dwProcessId)
          except KeyError:
              aProcess = Process(dwProcessId)
  
          # Cleanup all data referring to the process.
          self.__cleanup_process(dwProcessId,
                                 bIgnoreExceptions = bIgnoreExceptions)
  
          # Kill the process.
          try:
              try:
                  if self.is_debugee(dwProcessId):
                      try:
                          if aProcess.is_alive():
                              aProcess.suspend()
                      finally:
                          self.detach(dwProcessId,
                                      bIgnoreExceptions = bIgnoreExceptions)
              finally:
                  aProcess.kill()
          except Exception:
              if not bIgnoreExceptions:
                  raise
              e = sys.exc_info()[1]
              warnings.warn(str(e), RuntimeWarning)
  
          # Cleanup what remains of the process data.
          try:
              aProcess.clear()
          except Exception:
              if not bIgnoreExceptions:
                  raise
              e = sys.exc_info()[1]
              warnings.warn(str(e), RuntimeWarning)
docs: Kills a process currently being debugged.
  
          @see: L{detach}
  
          @type  dwProcessId: int
          @param dwProcessId: Global ID of a process to kill.
  
          @type  bIgnoreExceptions: bool
          @param bIgnoreExceptions: C{True} to ignore any exceptions that may be
              raised when killing the process.
  
          @raise WindowsError: Raises an exception on error, unless
              C{bIgnoreExceptions} is C{True}.