Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
43c317ef
Commit
43c317ef
authored
8 years ago
by
Evelyn
Committed by
GitHub
8 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update mg_broadcast.md
parent
01ffdb69
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
mg_broadcast.md
docs/c-api/net.h/mg_broadcast.md
+3
-3
No files found.
docs/c-api/net.h/mg_broadcast.md
View file @
43c317ef
...
@@ -6,14 +6,14 @@ signature: |
...
@@ -6,14 +6,14 @@ signature: |
void mg_broadcast(struct mg_mgr *, mg_event_handler_t func, void *, size_t);
void mg_broadcast(struct mg_mgr *, mg_event_handler_t func, void *, size_t);
---
---
Pass a message of a given length to all connections.
Pass
es
a message of a given length to all connections.
Must be called from a thread that does NOT call
`mg_mgr_poll()`
.
Must be called from a thread that does NOT call
`mg_mgr_poll()`
.
Note that
`mg_broadcast()`
is the only function
Note that
`mg_broadcast()`
is the only function
that can be, and must be, called from a different (non-IO) thread.
that can be, and must be, called from a different (non-IO) thread.
`func`
callback function will be called by the IO thread for each
`func`
callback function will be called by the IO thread for each
connection. When called,
event would be
`MG_EV_POLL`
, and
message will
connection. When called,
the event will be
`MG_EV_POLL`
, and a
message will
be passed as
`ev_data`
pointer. Maximum message size is capped
be passed as
the
`ev_data`
pointer. Maximum message size is capped
by
`MG_CTL_MSG_MESSAGE_SIZE`
which is set to 8192 bytes.
by
`MG_CTL_MSG_MESSAGE_SIZE`
which is set to 8192 bytes.
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment