mirror of
https://github.com/curl/curl.git
synced 2026-07-24 17:17:22 +03:00
curl: show the libcurl release date in --version output
... 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 Closes #1474
This commit is contained in:
parent
d836c9fee4
commit
180c75eb63
3 changed files with 11 additions and 5 deletions
|
|
@ -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) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue