MCPcopy Create free account
hub / github.com/davisking/dlib / start_async

Method start_async

dlib/server/server_kernel.cpp:173–188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

171// ----------------------------------------------------------------------------------------
172
173 void server::
174 start_async (
175 )
176 {
177 auto_mutex lock(running_mutex);
178 if (running)
179 return;
180
181 // Any exceptions likely to be thrown by the server are going to be
182 // thrown when trying to bind the port. So calling this here rather
183 // than in the thread we are about to make will cause start_async()
184 // to report errors back to the user in a very straight forward way.
185 open_listening_socket();
186
187 async_start_thread.reset(new thread_function(make_mfp(*this,&server::start_async_helper)));
188 }
189
190// ----------------------------------------------------------------------------------------
191

Callers

nothing calls this directly

Calls 2

make_mfpFunction · 0.85
resetMethod · 0.45

Tested by

no test coverage detected