@@ -73,7 +73,7 @@ namespace pthread {
7373 return rc;
7474 }
7575
76- thread::thread (): _status(thread_status::not_a_thread), _thread( 0 ) {
76+ thread::thread (): _thread( 0 ), _status(thread_status::not_a_thread) {
7777
7878 // intentional..
7979 }
@@ -129,7 +129,7 @@ namespace pthread {
129129 std::swap (_status, other._status );
130130 }
131131
132- abstract_thread::abstract_thread (const std::size_t stack_size): _stack_size(stack_size ), _thread( NULL ){
132+ abstract_thread::abstract_thread (const std::size_t stack_size): _thread( NULL ), _stack_size(stack_size ){
133133 }
134134
135135 abstract_thread::~abstract_thread (){
@@ -179,7 +179,7 @@ namespace pthread {
179179 printf (" thread_group destructor failed to join one thread. %s, (%d) %s.\n " , err.what (), err.pthread_errno (), err.pthread_errmsg ());
180180 } catch ( ... ){ // NOSONAR this was done on purpose to avoid crashes due to unhandled error conditions. This should never happen.
181181 printf (" thread_group destructor received an unexpected exception when joining threads." );
182- };
182+ }
183183 }
184184 }
185185 }
@@ -208,11 +208,16 @@ namespace pthread {
208208 }
209209
210210 /* *
211- This function is a helper function. It has normal C linkage, and is
212- the base for newly created Thread objects. It runs the
213- run method on the thread object passed to it (as a void *).
211+ * This function is a helper function. It has normal C linkage, and is
212+ * the base for newly created Thread objects. It runs the
213+ * run method on the thread object passed to it (as a void *).
214+ *
215+ * This is the signature that the POSIX threading library imposes.
216+ *
217+ * @param runner runnable interface.
218+ * @return unknown
214219 */
215- void *thread_startup_runnable (void *runner) {
220+ void *thread_startup_runnable (void *runner) { // NOSONAR
216221
217222 try {
218223 static_cast <runnable *>(runner)->run ();
0 commit comments