Skip to content

Commit

Permalink
tools/liblockdep: Fix initialization code path
Browse files Browse the repository at this point in the history
This makes initialization actually happen. Without it, initialization is
always skipped due to an incorrect conditional statement.

Signed-off-by: Ira W. Snyder <iws@ovro.caltech.edu>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
  • Loading branch information
Ira W. Snyder authored and Sasha Levin committed Feb 27, 2014
1 parent 38dbfb5 commit 367d896
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/lib/lockdep/preload.c
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ int pthread_rwlock_unlock(pthread_rwlock_t *rwlock)

__attribute__((constructor)) static void init_preload(void)
{
if (__init_state != done)
if (__init_state == done)
return;

#ifndef __GLIBC__
Expand Down

0 comments on commit 367d896

Please sign in to comment.