Remove temporary logging.

Bug: 199
Change-Id: Ic8eb3e7901b89e5a57c959c650ea316e2eeeb45a
Reviewed-on: https://boringssl-review.googlesource.com/22424
Commit-Queue: David Benjamin <davidben@google.com>
Commit-Queue: Steven Valdez <svaldez@google.com>
Reviewed-by: Steven Valdez <svaldez@google.com>
CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
David Benjamin 2017-10-30 16:28:22 -04:00 committed by CQ bot account: commit-bot@chromium.org
parent 4281bcd5d2
commit ba94746eb2
2 changed files with 3 additions and 17 deletions

View File

@ -1101,7 +1101,6 @@ static void MessageCallback(int is_write, int version, int content_type,
// Connect returns a new socket connected to localhost on |port| or -1 on
// error.
static int Connect(uint16_t port) {
time_t start_time = time(nullptr);
for (int af : { AF_INET6, AF_INET }) {
int sock = socket(af, SOCK_STREAM, 0);
if (sock == -1) {
@ -1148,11 +1147,6 @@ static int Connect(uint16_t port) {
}
PrintSocketError("connect");
// TODO(davidben): Remove this logging when https://crbug.com/boringssl/199 is
// resolved.
fprintf(stderr, "start_time = %lld, end_time = %lld\n",
static_cast<long long>(start_time),
static_cast<long long>(time(nullptr)));
return -1;
}

View File

@ -903,26 +903,18 @@ func acceptOrWait(listener *net.TCPListener, waitChan chan error) (net.Conn, err
type connOrError struct {
conn net.Conn
err error
startTime, endTime time.Time
}
connChan := make(chan connOrError, 1)
go func() {
startTime := time.Now()
if !*useGDB {
listener.SetDeadline(time.Now().Add(*idleTimeout))
}
conn, err := listener.Accept()
endTime := time.Now()
connChan <- connOrError{conn, err, startTime, endTime}
connChan <- connOrError{conn, err}
close(connChan)
}()
select {
case result := <-connChan:
if result.err != nil {
// TODO(davidben): Remove this logging when
// https://crbug.com/boringssl/199 is resolved.
fmt.Fprintf(os.Stderr, "acceptOrWait failed, startTime=%v, endTime=%v\n", result.startTime, result.endTime)
}
return result.conn, result.err
case childErr := <-waitChan:
waitChan <- childErr