code: def process_input_buffer():
      
      from polysh.control_commands_helpers import handle_control_command
      data = the_stdin_thread.input_buffer.get()
      remote_dispatcher.log(b'> ' + data)
  
      if data.startswith(b':'):
          try:
              handle_control_command(data[1:-1].decode())
          except UnicodeDecodeError as e:
              console_output(b'Could not decode command.')
          return
  
      if data.startswith(b'!'):
          try:
              retcode = subprocess.call(data[1:], shell=True)
          except OSError as e:
              if e.errno == errno.EINTR:
                  console_output(b'Child was interrupted\n')
                  retcode = 0
              else:
                  raise
          if retcode > 128 and retcode <= 192:
              retcode = 128 - retcode
          if retcode > 0:
              console_output('Child returned {:d}\n'.format(retcode).encode())
          elif retcode < 0:
              console_output('Child was terminated by signal {:d}\n'.format(
                  -retcode).encode())
          return
  
      for r in dispatchers.all_instances():
          try:
              r.dispatch_command(data)
          except asyncore.ExitNow as e:
              raise e
          except Exception as msg:
              raise msg
              console_output('{} for {}, disconnecting\n'.format(
                  str(msg), r.display_name).encode())
              r.disconnect()
          else:
              if r.enabled and r.state is remote_dispatcher.STATE_IDLE:
                  r.change_state(remote_dispatcher.STATE_RUNNING)
docs: Send the content of the input buffer to all remote processes, this must
      be called in the main thread