| 212 | // ---------------------------------------------------------------------------------------- |
| 213 | |
| 214 | void threaded_object:: |
| 215 | stop ( |
| 216 | ) |
| 217 | { |
| 218 | auto_mutex M(m_); |
| 219 | |
| 220 | DLIB_ASSERT(id1 != get_thread_id() || id_valid == false, |
| 221 | "\tvoid threaded_object::stop()" |
| 222 | << "\n\tYou can NOT call this function from the thread that executes threaded_object::thread" |
| 223 | << "\n\tthis: " << this |
| 224 | ); |
| 225 | |
| 226 | should_stop_ = true; |
| 227 | is_running_ = false; |
| 228 | should_respawn_ = false; |
| 229 | s.broadcast(); |
| 230 | } |
| 231 | |
| 232 | // ---------------------------------------------------------------------------------------- |
| 233 |
nothing calls this directly
no test coverage detected