This is an automated email from the ASF dual-hosted git repository.
rrm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 0fe8937 Update jtest.cc
0fe8937 is described below
commit 0fe89372bf4e9881df1b37ddf0c6979c8b4f2feb
Author: hankai17 <[email protected]>
AuthorDate: Tue Apr 30 22:30:47 2019 +0800
Update jtest.cc
---
tools/jtest/jtest.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/jtest/jtest.cc b/tools/jtest/jtest.cc
index da22fe1..4253d04 100644
--- a/tools/jtest/jtest.cc
+++ b/tools/jtest/jtest.cc
@@ -1806,7 +1806,7 @@ poll_loop()
if (ip >= POLL_GROUP_SIZE || i == last_fd) {
int n = poll(pfd, ip, POLL_TIMEOUT);
if (n > 0) {
- for (int j = 0; j < ip; j++) {
+ for (int j = 0; j < n; j++) {
if (pfd[j].revents & (POLLIN | POLLERR | POLLHUP | POLLNVAL)) {
if (verbose) {
printf("poll read %d %X\n", pfd[j].fd, pfd[j].revents);