docs: def process_end(self, marker):
          """ Reads and processes DONE/DONEINPROC/DONEPROC streams
  
          Stream format urls:
  
          - DONE: http://msdn.microsoft.com/en-us/library/dd340421.aspx
          - DONEINPROC: http://msdn.microsoft.com/en-us/library/dd340553.aspx
          - DONEPROC: http://msdn.microsoft.com/en-us/library/dd340753.aspx
  
          :param marker: Can be TDS_DONE_TOKEN or TDS_DONEINPROC_TOKEN or TDS_DONEPROC_TOKEN
          """
          code_to_str = {
              tds_base.TDS_DONE_TOKEN: 'DONE',
              tds_base.TDS_DONEINPROC_TOKEN: 'DONEINPROC',
              tds_base.TDS_DONEPROC_TOKEN: 'DONEPROC',
          }
          self.end_marker = marker
          self.more_rows = False
          r = self._reader
          status = r.get_usmallint()
          r.get_usmallint()  # cur_cmd
          more_results = status & tds_base.TDS_DONE_MORE_RESULTS != 0
          was_cancelled = status & tds_base.TDS_DONE_CANCELLED != 0
          done_count_valid = status & tds_base.TDS_DONE_COUNT != 0
          if self.res_info:
              self.res_info.more_results = more_results
          rows_affected = r.get_int8() if tds_base.IS_TDS72_PLUS(self) else r.get_int()
          self.log_response_message("got {} message, more_res={}, cancelled={}, rows_affected={}".format(
              code_to_str[marker], more_results, was_cancelled, rows_affected))
          if was_cancelled or (not more_results and not self.in_cancel):
              self.in_cancel = False
              self.set_state(tds_base.TDS_IDLE)
          if done_count_valid:
              self.rows_affected = rows_affected
          else:
              self.rows_affected = -1
          self.done_flags = status
          if self.done_flags & tds_base.TDS_DONE_ERROR and not was_cancelled and not self.in_cancel:
              self.raise_db_exception()