use volatile for the stop flag

CCBUGS: 383204
1 job for master
Status Job ID Name Coverage
  Build
canceled #56276
linux kf5-qt5 qt5.12