trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From geor...@apache.org
Subject svn commit: r904528 - /incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc
Date Fri, 29 Jan 2010 15:50:11 GMT
Author: georgep
Date: Fri Jan 29 15:50:11 2010
New Revision: 904528

URL: http://svn.apache.org/viewvc?rev=904528&view=rev
Log:
TS-122: This patch 'TS122_patch1.diff' fixes the incorrect use of the condition variable in
'librecords'.
Tested: ubuntu904,fedora11

Modified:
    incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc

Modified: incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc
URL: http://svn.apache.org/viewvc/incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc?rev=904528&r1=904527&r2=904528&view=diff
==============================================================================
--- incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc (original)
+++ incubator/trafficserver/traffic/trunk/librecords/RecProcess.cc Fri Jan 29 15:50:11 2010
@@ -152,7 +152,9 @@
   int err;
   if ((err = recv_message_cb(msg, msg_type, cookie)) == REC_ERR_OKAY) {
     if (msg_type == RECG_PULL_ACK) {
+      ink_mutex_acquire(&g_force_req_mutex);
       ink_cond_signal(&g_force_req_cond);
+      ink_mutex_release(&g_force_req_mutex);
     }
   }
   return err;
@@ -331,6 +333,7 @@
   ink_mutex_init(&g_force_req_mutex, NULL);
   if (mode_type == RECM_CLIENT) {
     send_pull_message(RECG_PULL_REQ);
+    ink_mutex_acquire(&g_force_req_mutex);
     ink_cond_wait(&g_force_req_cond, &g_force_req_mutex);
     ink_mutex_release(&g_force_req_mutex);
   }



Mime
View raw message