misc/cgo/testcshared: wait up to 1 second in main2.c

Wait longer in case the system is heavily loaded.

Fixes #18324.

Change-Id: If9a6da1cf32d0321302d244ee24fb3f80e54489d
Reviewed-on: https://go-review.googlesource.com/34653
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
Ian Lance Taylor 2016-12-19 19:46:54 -08:00
parent 5a72bad87a
commit 860c9c0b8d

View file

@ -21,7 +21,7 @@ int main(void) {
// The descriptor will be initialized in a thread, so we have to
// give a chance to get opened.
for (i = 0; i < 100; i++) {
for (i = 0; i < 1000; i++) {
n = read(fd, buf, sizeof buf);
if (n >= 0)
break;