Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
WebServer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
loposuezo
WebServer
Commits
94944f32
Commit
94944f32
authored
1 year ago
by
codecraft
Browse files
Options
Downloads
Patches
Plain Diff
Remove unnecessary println! and updated some of the code
Added TODO: file
parent
61af39db
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
TODO.md
+9
-0
9 additions, 0 deletions
TODO.md
core/http/src/handlers/handlers.rs
+0
-1
0 additions, 1 deletion
core/http/src/handlers/handlers.rs
core/http/src/handling/request.rs
+1
-1
1 addition, 1 deletion
core/http/src/handling/request.rs
with
10 additions
and
2 deletions
TODO.md
0 → 100644
+
9
−
0
View file @
94944f32
1.
If you collect an iterator which you don't index in, you don't need to collect it
2.
avoid temporary hashmaps
3.
rewrite POST request stuff TICK
4.
Client struct
5.
Mime-Display new implemented
6.
Remove unwraps
7.
Reusable allocations
API design 3. No decisions for the caller
This diff is collapsed.
Click to expand it.
core/http/src/handlers/handlers.rs
+
0
−
1
View file @
94944f32
...
@@ -61,7 +61,6 @@ pub async fn handle_connection(mut stream: TcpStream, mountpoints: Vec<MountPoin
...
@@ -61,7 +61,6 @@ pub async fn handle_connection(mut stream: TcpStream, mountpoints: Vec<MountPoin
buffer
:
vec!
[],
buffer
:
vec!
[],
};
};
if
request
.can_have_body
()
{
if
request
.can_have_body
()
{
println!
(
"{:#?}"
,
request
.headers
);
let
length
=
if
let
Some
(
len
)
=
request
let
length
=
if
let
Some
(
len
)
=
request
.headers
.headers
.iter
()
.iter
()
...
...
This diff is collapsed.
Click to expand it.
core/http/src/handling/request.rs
+
1
−
1
View file @
94944f32
...
@@ -221,7 +221,7 @@ impl Request<'_> {
...
@@ -221,7 +221,7 @@ impl Request<'_> {
let
end_boundary
=
format!
(
"{temp_bound}--
\r
"
)
.as_bytes
()
.to_owned
();
let
end_boundary
=
format!
(
"{temp_bound}--
\r
"
)
.as_bytes
()
.to_owned
();
temp_bound
.push
(
'\r'
);
temp_bound
.push
(
'\r'
);
let
boundary
=
temp_bound
.as_bytes
();
let
boundary
=
temp_bound
.as_bytes
();
Request
::
get_multipart_data
(
data
,
boundary
,
&
end_boundary
,
&
mut
keymap
);
Self
::
get_multipart_data
(
data
,
boundary
,
&
end_boundary
,
&
mut
keymap
);
}
}
_
=>
{
_
=>
{
return
Err
(
ParseFormError
{
return
Err
(
ParseFormError
{
...
...
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