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
4031eb1d
Commit
4031eb1d
authored
18 years ago
by
Gisle Vanem
Browse files
Options
Downloads
Patches
Plain Diff
Avoid Metaware's High-C warning "'=' encountered where '==' may have been intended."
parent
59cf6fd4
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
lib/dict.c
+1
-1
1 addition, 1 deletion
lib/dict.c
lib/formdata.c
+12
-12
12 additions, 12 deletions
lib/formdata.c
lib/ftp.c
+5
-3
5 additions, 3 deletions
lib/ftp.c
lib/hostip4.c
+1
-1
1 addition, 1 deletion
lib/hostip4.c
with
19 additions
and
17 deletions
lib/dict.c
+
1
−
1
View file @
4031eb1d
...
...
@@ -106,7 +106,7 @@ static char *unescape_word(struct SessionHandle *data, char *inp)
/* According to RFC2229 section 2.2, these letters need to be escaped with
\[letter] */
for
(
ptr
=
newp
;
(
byte
=
(
unsigned
char
)
*
ptr
);
(
byte
=
(
unsigned
char
)
*
ptr
)
!=
0
;
ptr
++
)
{
if
((
byte
<=
32
)
||
(
byte
==
127
)
||
(
byte
==
'\''
)
||
(
byte
==
'\"'
)
||
(
byte
==
'\\'
))
{
...
...
This diff is collapsed.
Click to expand it.
lib/formdata.c
+
12
−
12
View file @
4031eb1d
...
...
@@ -528,8 +528,8 @@ CURLFORMcode FormAdd(struct curl_httppost **httppost,
if
(
current_form
->
value
)
{
if
(
current_form
->
flags
&
HTTPPOST_FILENAME
)
{
if
(
filename
)
{
if
(
!
(
current_form
=
AddFormInfo
(
strdup
(
filename
),
NULL
,
current_form
)))
if
((
current_form
=
AddFormInfo
(
strdup
(
filename
),
NULL
,
current_form
))
==
NULL
)
return_value
=
CURL_FORMADD_MEMORY
;
}
else
...
...
@@ -562,8 +562,8 @@ CURLFORMcode FormAdd(struct curl_httppost **httppost,
if
(
current_form
->
value
)
{
if
(
current_form
->
flags
&
HTTPPOST_BUFFER
)
{
if
(
filename
)
{
if
(
!
(
current_form
=
AddFormInfo
(
strdup
(
filename
),
NULL
,
current_form
)))
if
((
current_form
=
AddFormInfo
(
strdup
(
filename
),
NULL
,
current_form
))
==
NULL
)
return_value
=
CURL_FORMADD_MEMORY
;
}
else
...
...
@@ -614,9 +614,9 @@ CURLFORMcode FormAdd(struct curl_httppost **httppost,
if
(
current_form
->
contenttype
)
{
if
(
current_form
->
flags
&
HTTPPOST_FILENAME
)
{
if
(
contenttype
)
{
if
(
!
(
current_form
=
AddFormInfo
(
NULL
,
strdup
(
contenttype
),
current_form
)))
if
((
current_form
=
AddFormInfo
(
NULL
,
strdup
(
contenttype
),
current_form
))
==
NULL
)
return_value
=
CURL_FORMADD_MEMORY
;
}
else
...
...
@@ -884,7 +884,7 @@ void Curl_formclean(struct FormData *form)
free
(
form
->
line
);
/* free the line */
free
(
form
);
/* free the struct */
}
while
((
form
=
next
));
/* continue */
}
while
((
form
=
next
)
!=
NULL
);
/* continue */
}
/*
...
...
@@ -961,7 +961,7 @@ void curl_formfree(struct curl_httppost *form)
free
(
form
->
showfilename
);
/* free the faked file name */
free
(
form
);
/* free the struct */
}
while
((
form
=
next
));
/* continue */
}
while
((
form
=
next
)
!=
NULL
);
/* continue */
}
#ifndef HAVE_BASENAME
...
...
@@ -1231,7 +1231,7 @@ CURLcode Curl_getFormData(struct FormData **finalform,
*/
size_t
nread
;
char
buffer
[
512
];
while
((
nread
=
fread
(
buffer
,
1
,
sizeof
(
buffer
),
fileread
)))
{
while
((
nread
=
fread
(
buffer
,
1
,
sizeof
(
buffer
),
fileread
))
!=
0
)
{
result
=
AddFormData
(
&
form
,
FORM_DATA
,
buffer
,
nread
,
&
size
);
if
(
result
)
break
;
...
...
@@ -1268,7 +1268,7 @@ CURLcode Curl_getFormData(struct FormData **finalform,
if
(
result
)
break
;
}
}
while
((
file
=
file
->
more
));
/* for each specified file for this field */
}
while
((
file
=
file
->
more
)
!=
NULL
);
/* for each specified file for this field */
if
(
result
)
{
Curl_formclean
(
firstform
);
free
(
boundary
);
...
...
@@ -1286,7 +1286,7 @@ CURLcode Curl_getFormData(struct FormData **finalform,
break
;
}
}
while
((
post
=
post
->
next
));
/* for each field */
}
while
((
post
=
post
->
next
)
!=
NULL
);
/* for each field */
if
(
result
)
{
Curl_formclean
(
firstform
);
free
(
boundary
);
...
...
This diff is collapsed.
Click to expand it.
lib/ftp.c
+
5
−
3
View file @
4031eb1d
...
...
@@ -138,8 +138,10 @@ static int ftp_need_type(struct connectdata *conn,
bool
ascii
);
/* easy-to-use macro: */
#define FTPSENDF(x,y,z) if((result = Curl_ftpsendf(x,y,z))) return result
#define NBFTPSENDF(x,y,z) if((result = Curl_nbftpsendf(x,y,z))) return result
#define FTPSENDF(x,y,z) if ((result = Curl_ftpsendf(x,y,z)) != CURLE_OK) \
return result
#define NBFTPSENDF(x,y,z) if ((result = Curl_nbftpsendf(x,y,z)) != CURLE_OK) \
return result
static
void
freedirs
(
struct
FTP
*
ftp
)
{
...
...
@@ -3878,7 +3880,7 @@ CURLcode ftp_parse_url_path(struct connectdata *conn)
return
CURLE_OUT_OF_MEMORY
;
/* parse the URL path into separate path components */
while
((
slash_pos
=
strchr
(
cur_pos
,
'/'
)))
{
while
((
slash_pos
=
strchr
(
cur_pos
,
'/'
))
!=
NULL
)
{
/* 1 or 0 to indicate absolute directory */
bool
absolute_dir
=
(
cur_pos
-
conn
->
path
>
0
)
&&
(
ftp
->
dirdepth
==
0
);
...
...
This diff is collapsed.
Click to expand it.
lib/hostip4.c
+
1
−
1
View file @
4031eb1d
...
...
@@ -348,7 +348,7 @@ Curl_addrinfo *Curl_he2ai(const struct hostent *he, int port)
/* no input == no output! */
return
NULL
;
for
(
i
=
0
;
(
curr
=
(
struct
in_addr
*
)
he
->
h_addr_list
[
i
]);
i
++
)
{
for
(
i
=
0
;
(
curr
=
(
struct
in_addr
*
)
he
->
h_addr_list
[
i
])
!=
NULL
;
i
++
)
{
ai
=
calloc
(
1
,
sizeof
(
Curl_addrinfo
)
+
sizeof
(
struct
sockaddr_in
));
...
...
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