Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
TLMSP curl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CYBER - Cyber Security
TS 103 523 MSP
TLMSP
TLMSP curl
Commits
5974309d
Commit
5974309d
authored
21 years ago
by
Daniel Stenberg
Browse files
Options
Downloads
Patches
Plain Diff
CURLINFO_RESPONSE_CODE replaces CURLINFO_HTTP_CODE
parent
d00e4a37
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
include/curl/curl.h
+5
-1
5 additions, 1 deletion
include/curl/curl.h
lib/getinfo.c
+1
-1
1 addition, 1 deletion
lib/getinfo.c
src/writeenv.c
+1
-1
1 addition, 1 deletion
src/writeenv.c
src/writeout.c
+1
-1
1 addition, 1 deletion
src/writeout.c
with
8 additions
and
4 deletions
include/curl/curl.h
+
5
−
1
View file @
5974309d
...
...
@@ -979,7 +979,7 @@ time_t curl_getdate(const char *p, const time_t *now);
typedef
enum
{
CURLINFO_NONE
,
/* first, never use this */
CURLINFO_EFFECTIVE_URL
=
CURLINFO_STRING
+
1
,
CURLINFO_
HTTP
_CODE
=
CURLINFO_LONG
+
2
,
CURLINFO_
RESPONSE
_CODE
=
CURLINFO_LONG
+
2
,
CURLINFO_TOTAL_TIME
=
CURLINFO_DOUBLE
+
3
,
CURLINFO_NAMELOOKUP_TIME
=
CURLINFO_DOUBLE
+
4
,
CURLINFO_CONNECT_TIME
=
CURLINFO_DOUBLE
+
5
,
...
...
@@ -1005,6 +1005,10 @@ typedef enum {
CURLINFO_LASTONE
=
23
}
CURLINFO
;
/* CURLINFO_RESPONSE_CODE is the new name for the option previously known as
CURLINFO_HTTP_CODE */
#define CURLINFO_HTTP_CODE CURLINFO_RESPONSE_CODE
typedef
enum
{
CURLCLOSEPOLICY_NONE
,
/* first, never use this */
...
...
This diff is collapsed.
Click to expand it.
lib/getinfo.c
+
1
−
1
View file @
5974309d
...
...
@@ -103,7 +103,7 @@ CURLcode Curl_getinfo(struct SessionHandle *data, CURLINFO info, ...)
case
CURLINFO_EFFECTIVE_URL
:
*
param_charp
=
data
->
change
.
url
?
data
->
change
.
url
:
(
char
*
)
""
;
break
;
case
CURLINFO_
HTTP
_CODE
:
case
CURLINFO_
RESPONSE
_CODE
:
*
param_longp
=
data
->
info
.
httpcode
;
break
;
case
CURLINFO_HTTP_CONNECTCODE
:
...
...
This diff is collapsed.
Click to expand it.
src/writeenv.c
+
1
−
1
View file @
5974309d
...
...
@@ -44,7 +44,7 @@ struct
}
variables
[
14
]
=
{
{
"curl_url_effective"
,
CURLINFO_EFFECTIVE_URL
,
writeenv_STRING
},
{
"curl_http_code"
,
CURLINFO_
HTTP
_CODE
,
writeenv_LONG
},
{
"curl_http_code"
,
CURLINFO_
RESPONSE
_CODE
,
writeenv_LONG
},
{
"curl_time_total"
,
CURLINFO_TOTAL_TIME
,
writeenv_DOUBLE
},
{
"curl_time_namelookup"
,
CURLINFO_NAMELOOKUP_TIME
,
writeenv_DOUBLE
},
{
"curl_time_connect"
,
CURLINFO_CONNECT_TIME
,
writeenv_DOUBLE
},
...
...
This diff is collapsed.
Click to expand it.
src/writeout.c
+
1
−
1
View file @
5974309d
...
...
@@ -118,7 +118,7 @@ void ourWriteOut(CURL *curl, char *writeinfo)
break
;
case
VAR_HTTP_CODE
:
if
(
CURLE_OK
==
curl_easy_getinfo
(
curl
,
CURLINFO_
HTTP
_CODE
,
&
longinfo
))
curl_easy_getinfo
(
curl
,
CURLINFO_
RESPONSE
_CODE
,
&
longinfo
))
fprintf
(
stream
,
"%03d"
,
longinfo
);
break
;
case
VAR_HEADER_SIZE
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment