cURL / Mailing Lists / curl-users / Single Mail

curl-users

time stamps in -v output?

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Sun, 1 May 2005 01:02:21 +0200 (CEST)

Hello good people!

I'm sitting here trying to figure out why a test case fails on a particular
box. The test cases generates a range of logs from all servers and helper
tools.

To properly figure out exactly what command curl sends that trigger exactly
what results in the server ends, I needed time stamps added to curl's verbose
display output.

So I added it. (The entire change is made outside of libcurl - I'm now using
DEBUGFUNCTION even for -v.) See the attached patch for all details.

While at it, I fixed a few other "faults" and now my output looks like shown
below.

My questions for the audience are:

1) can I modify the general -v output this much without it hitting some
people in the face?

2) If not, should I instead add a --trace-plain or perhaps --trace-timestamp
option?

3) Would the other --trace-* functions also benefit from getting this
timestamp prepended?

This is how it looks:

$ curl -v curl.haxx.se
00:54:39.76 * About to connect() to curl.haxx.se port 80
00:54:39.76 * Trying 193.15.23.28... connected
00:54:39.76 * Connected to curl.haxx.se (193.15.23.28) port 80
00:54:39.76 > GET / HTTP/1.1
00:54:39.76 > User-Agent: curl/7.14.0-CVS (i686-pc-linux-gnu)
libcurl/7.14.0-CVS OpenSSL/0.9.7e zlib/1.2.2 libidn/0.5.13
00:54:39.76 > Host: curl.haxx.se
00:54:39.76 > Pragma: no-cache
00:54:39.76 > Accept: */*
00:54:39.76 >
00:54:39.78 < HTTP/1.1 200 OK
00:54:39.78 < Date: Sat, 30 Apr 2005 22:54:39 GMT
00:54:39.78 < Server: Apache/1.3.26 (Unix) Debian GNU/Linux PHP/4.1.2
mod_ssl/2.8.9 OpenSSL/0.9.6c
00:54:39.78 < Last-Modified: Sat, 30 Apr 2005 22:40:07 GMT
00:54:39.78 < ETag: "50ad8-322d-42740947"
00:54:39.78 < Accept-Ranges: bytes
00:54:39.78 < Content-Length: 12845
00:54:39.78 < Content-Type: text/html; charset=iso-8859-1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
...

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html

Received on 2005-05-01