Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fanout
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
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
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gerhard Gonter
fanout
Commits
cf63d632
Commit
cf63d632
authored
Oct 17, 2012
by
Travis Glenn Hansen
Browse files
Options
Downloads
Patches
Plain Diff
fixed ipv6 issues
parent
da910d54
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
fanout.c
+11
-18
11 additions, 18 deletions
fanout.c
with
11 additions
and
18 deletions
fanout.c
+
11
−
18
View file @
cf63d632
...
...
@@ -599,10 +599,8 @@ resetting counter\n");
clients_count
++
;
}
else
{
// Process events of other sockets...
client_i
=
client_head
;
while
(
client_i
!=
NULL
)
{
if
(
efd
==
client_i
->
fd
)
{
//should be an existing client connection
if
((
client_i
=
get_client
(
efd
))
!=
NULL
)
{
// Process data from socket i
fanout_debug
(
3
,
"processing client %d
\n
"
,
client_i
->
fd
);
...
...
@@ -618,7 +616,6 @@ resetting counter\n");
}
fanout_debug
(
3
,
"client socket removed from epoll watch list
\n
"
);
shutdown_client
(
client_i
);
break
;
}
else
{
// Process data in buffer
fanout_debug
(
3
,
"%d bytes read: [%.*s]
\n
"
,
res
,
...
...
@@ -627,13 +624,10 @@ resetting counter\n");
client_i
->
input_buffer
,
buffer
);
client_process_input_buffer
(
client_i
);
break
;
}
}
client_i
=
client_i
->
next
;
if
(
client_i
!=
NULL
)
fanout_debug
(
3
,
"moving to client_i %d
\n
"
,
client_i
->
fd
);
}
//end while (client_i != NULL)
break
;
}
//end else
}
//end for
}
//end while (1)
...
...
@@ -888,10 +882,9 @@ struct client *get_client (int fd)
void
remove_client
(
struct
client
*
c
)
{
//char *peer = getsocketpeername (c->fd);
//fanout_debug (3, "removing client %d connected from %s from service\n",
fanout_debug
(
3
,
"removing client %d connected from service
\n
"
,
c
->
fd
);
char
*
peer
=
getsocketpeername
(
c
->
fd
);
fanout_debug
(
3
,
"removing client %d connected from %s from service
\n
"
,
c
->
fd
,
peer
);
if
(
c
->
next
!=
NULL
)
{
if
(
c
->
previous
!=
NULL
)
fanout_debug
(
3
,
"setting previous on %d to %d
\n
"
,
...
...
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