Skip to contentSkip to conversation

pthread_mutex_lock/3-1: make sure install signal hanldler first

PATCH New Kang Kai 1 participant 1 message Dec 2, 2011

lore
Share & tools
lore

Kang Kai

author
#0 lore raw

PATCH 1/1 pthread_mutex_lock/3-1: make sure install signal hanldler first

Test case failed for linux in some platform. Make parent thread sleep for a while to make sure that signal handlers are installed before send signal USR1 and USR2.

---
 .../interfaces/pthread_mutex_lock/3-1.c            |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
testcases/open_posix_testsuite/conformance/interfaces/pthread_mutex_lock/3-1.c +3 -1
index 771851d..a648c96 100644
@@ -307,6 +307,8 @@ int main (int argc, char * argv[])
 	if ((ret = pthread_create(&th_work, NULL, threaded, NULL)))
 	{ UNRESOLVED(ret, "Worker thread creation failed"); }
 
+	sleep(1);
+
 	arg1.thr = &th_work;
 	arg2.thr = &th_work;
 	arg1.sig = SIGUSR1;
@@ -359,4 +361,4 @@ int main (int argc, char * argv[])
 	#endif
 	#endif
 	PASSED;
-}
\ No newline at end of file
+}
Signature · 13 lines
1.7.5.4


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure 
contains a definitive record of customers, application performance, 
security threats, fraudulent activity, and more. Splunk takes this 
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list