Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pcom-laboratoare-public
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
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
Code review analytics
Issue analytics
Insights
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
Tudor-Andrei CORNESCU
pcom-laboratoare-public
Commits
3759e501
Commit
3759e501
authored
2 years ago
by
Ion-Dorinel FILIP (25005)
Browse files
Options
Downloads
Patches
Plain Diff
Removed outdated TODO
parent
29bdae16
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lab7/server.c
+2
-2
2 additions, 2 deletions
lab7/server.c
with
2 additions
and
2 deletions
lab7/server.c
+
2
−
2
View file @
3759e501
...
@@ -26,7 +26,7 @@ int receive_and_send(int connfd1, int connfd2, size_t len) {
...
@@ -26,7 +26,7 @@ int receive_and_send(int connfd1, int connfd2, size_t len) {
int
bytes_received
;
int
bytes_received
;
char
buffer
[
len
];
char
buffer
[
len
];
//
TODO 2.1: Foloseste recv_all ca să primești
exact len octeti de la connfd1
//
Primim
exact len octeti de la connfd1
bytes_received
=
recv_all
(
connfd1
,
buffer
,
len
);
bytes_received
=
recv_all
(
connfd1
,
buffer
,
len
);
// S-a inchis conexiunea
// S-a inchis conexiunea
if
(
bytes_received
==
0
)
{
if
(
bytes_received
==
0
)
{
...
@@ -34,7 +34,7 @@ int receive_and_send(int connfd1, int connfd2, size_t len) {
...
@@ -34,7 +34,7 @@ int receive_and_send(int connfd1, int connfd2, size_t len) {
}
}
DIE
(
bytes_received
<
0
,
"recv"
);
DIE
(
bytes_received
<
0
,
"recv"
);
// T
ODO 2.2: Foloseste send_all ca sa t
rimit
i
mesajul catre connfd2
// Trimit
em
mesajul catre connfd2
int
rc
=
send_all
(
connfd2
,
buffer
,
len
);
int
rc
=
send_all
(
connfd2
,
buffer
,
len
);
if
(
rc
<=
0
)
{
if
(
rc
<=
0
)
{
perror
(
"send_all"
);
perror
(
"send_all"
);
...
...
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