From 131211b4daf83b7c594337f4e7c71e4711094d71 Mon Sep 17 00:00:00 2001 From: erdgeist <> Date: Tue, 13 Jan 2009 22:41:17 +0000 Subject: V6 --- ot_mutex.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ot_mutex.c') diff --git a/ot_mutex.c b/ot_mutex.c index 6edfaef..36de5ff 100644 --- a/ot_mutex.c +++ b/ot_mutex.c @@ -80,8 +80,8 @@ ot_vector *mutex_bucket_lock( int bucket ) { return all_torrents + bucket; } -ot_vector *mutex_bucket_lock_by_hash( ot_hash *hash ) { - int bucket = uint32_read_big( (char*)*hash ) >> OT_BUCKET_COUNT_SHIFT; +ot_vector *mutex_bucket_lock_by_hash( ot_hash hash ) { + int bucket = uint32_read_big( (char*)hash ) >> OT_BUCKET_COUNT_SHIFT; /* Can block */ mutex_bucket_lock( bucket ); @@ -96,8 +96,8 @@ void mutex_bucket_unlock( int bucket, int delta_torrentcount ) { pthread_mutex_unlock( &bucket_mutex ); } -void mutex_bucket_unlock_by_hash( ot_hash *hash, int delta_torrentcount ) { - mutex_bucket_unlock( uint32_read_big( (char*)*hash ) >> OT_BUCKET_COUNT_SHIFT, delta_torrentcount ); +void mutex_bucket_unlock_by_hash( ot_hash hash, int delta_torrentcount ) { + mutex_bucket_unlock( uint32_read_big( (char*)hash ) >> OT_BUCKET_COUNT_SHIFT, delta_torrentcount ); } size_t mutex_get_torrent_count( ) { -- cgit v1.2.3