text: Title: UnicodeDecodeError when using subprocess.getstatusoutput
  Body: I've made this script for finding corrupt images using Imagemagick. Full code:
  ```
  from pathlib import Path
  import time
  import subprocess
  import concurrent.futures
  from tqdm import tqdm
  
  _err_set = set()
  
  
  def _imgerr(_img):
      global _err_set
      output = subprocess.getstatusoutput("magick identify -regard-warnings \"" + str(_img) + "\"")
      if(int(output[0]) == 1):
          _err_set.add(str(_img))
  
  
  _root = input("Input directory path: ")
  file_set = set(Path(_root).rglob("*.jpg"))
  
  print("Scanning...")
  start1 = time.perf_counter()
  with concurrent.futures.ThreadPoolExecutor() as executor:
      list(tqdm(executor.map(_imgerr, file_set),total=int(len(file_set)))) 
  finish1 = time.perf_counter()
  with open('bad_img.txt', 'w', encoding="utf-8") as f:
      for item in sorted(_err_set):
          f.write('"' + item + '"' + "\n")
  f.close()
  print(f'Total execution time [mt] = {round(finish1 - start1, 3)}s')
  print(f'Average time per image = {round((finish1 - start1)/len(file_set), 10)}s')
  print(f'Corrupt images = {len(_err_set)}')
  ```
  I'm using tqdm for progress tracking. The problem is with this line:
  ```
  list(tqdm(executor.map(_imgerr, file_set),total=int(len(file_set)))) 
  ```
  If there are no non ascii characters in the image path then everything works fine, but if any unicode character appears I get
  
  >Exception has occurred: UnicodeDecodeError 'charmap' codec can't decode byte 0x81 in position 37: character maps to /<undefined/>
  
  If I instead just use
  ```
  executor.map(_imgerr, file_set)
  ```
  everyting works just fine, regardless if there are unicode characters present or not. Been scratching my head for couple of hours now but still can't figure out what causes the error. Any suggestions are welcome! Btw maybe it's relevant but when debugging the error pops out in the function at the following line:
  ```
  output = subprocess.getstatusoutput("magick identify -regard-warnings \"" + str(_img) + "\"")
  ```
  