Bug 402341

Summary: drd/tests/tsan_thread_wrappers_pthread.h:369: suspicious code ?
Product: [Developer tools] valgrind Reporter: dcb314
Component: drdAssignee: Bart Van Assche <bart.vanassche+kde>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: 3.15 SVN   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description dcb314 2018-12-19 12:22:57 UTC
SUMMARY

rd/tests/tsan_thread_wrappers_pthread.h:371]: (warning) Identical condition 'my_thread->wpvpv_', second condition is always false

Source code is

    if (my_thread->wpvpv_)
      return my_thread->wpvpv_(my_thread->arg_);
    if (my_thread->wpvpv_)
      my_thread->wvpv_(my_thread->arg_);


STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
MacOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Bart Van Assche 2018-12-20 02:40:04 UTC
Thank you for your report. Please verify whether commit 5b4029b8cc8f ("drd/tests/tsan_thread_wrappers_pthread.h: Fix MyThread::ThreadBody()") fixes this bug.
Comment 2 dcb314 2018-12-20 08:14:35 UTC
In latest version, warning from static analyser no longer exists.

It looks fixed to me.