Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 10e71c9

Browse files
committed
Initialize rsocket in critical section
1 parent 170e545 commit 10e71c9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/common/pg_rsocket.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,12 +101,12 @@ static pthread_mutex_t rsocket_init_mutex = PTHREAD_MUTEX_INITIALIZER;
101101
void
102102
initialize_rsocket(void)
103103
{
104-
pthread_mutex_lock(rsocket_init_mutex);
104+
pthread_mutex_lock(&rsocket_init_mutex);
105105

106106
/* librdmacm was loaded already */
107107
if (rdmacm_handle != NULL)
108108
{
109-
pthread_mutex_unlock(rsocket_init_mutex);
109+
pthread_mutex_unlock(&rsocket_init_mutex);
110110
return;
111111
}
112112

@@ -169,7 +169,7 @@ initialize_rsocket(void)
169169
rcalls->fcntl = get_function("rfcntl");
170170
#endif
171171

172-
pthread_mutex_unlock(rsocket_init_mutex);
172+
pthread_mutex_unlock(&rsocket_init_mutex);
173173
}
174174

175175
#endif /* WITH_RSOCKET */

0 commit comments

Comments
 (0)