diff options
author | Daniel Stenberg <daniel@haxx.se> | 2017-05-11 08:39:06 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-05-11 13:24:53 +0200 |
commit | ac35a507fc57b996cfd1bf11821771db667ebb78 (patch) | |
tree | 41b4c7a29163f0c5d573f980d697748e8d8e958e /src/tool_help.c | |
parent | 77b90997dd228b071603c9ade96a16610a6df222 (diff) | |
download | curl-bagder/curl-version-date.tar.gz |
curl: show the libcurl release date in --version outputbagder/curl-version-date
... and support and additional "security patched" date for those who
enhance older versions that way. Pass on the define CURL_PATCHSTAMP with
a date for that.
Building with non-release headers shows the date as [unreleased].
Also: this changes the date format generated in the curlver.h file to be
"YYYY-MM-DD" (no name of the day or month, no time, no time zone) to
make it easier on the eye and easier to parse. Example (new) date
string: 2017-05-09
Suggested-by: Brian Childs
Diffstat (limited to 'src/tool_help.c')
-rw-r--r-- | src/tool_help.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tool_help.c b/src/tool_help.c index 668499cca..46aae4527 100644 --- a/src/tool_help.c +++ b/src/tool_help.c @@ -516,6 +516,12 @@ void tool_version_info(void) const char *const *proto; printf(CURL_ID "%s\n", curl_version()); +#ifdef CURL_PATCHSTAMP + printf("Release-Date: %s, security patched: %s\n", + LIBCURL_TIMESTAMP, CURL_PATCHSTAMP); +#else + printf("Release-Date: %s\n", LIBCURL_TIMESTAMP); +#endif if(curlinfo->protocols) { printf("Protocols: "); for(proto = curlinfo->protocols; *proto; ++proto) { |