Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
A
ademco_hb
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
ademco_hb
Commits
e241b40c
Commit
e241b40c
authored
Jul 30, 2020
by
captainwong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix seq
parent
ed6c3045
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
server_demo_libevent.cpp
examples/server_demo_libevent/server_demo_libevent.cpp
+4
-4
No files found.
examples/server_demo_libevent/server_demo_libevent.cpp
View file @
e241b40c
...
...
@@ -127,11 +127,11 @@ void commandcb(evutil_socket_t, short, void* user_data)
std
::
lock_guard
<
std
::
mutex
>
lg
(
context
->
mutex
);
for
(
auto
&
client
:
context
->
clients
)
{
for
(
auto
e
:
evs
)
{
if
(
++
client
.
second
.
seq
==
10000
)
{
client
.
second
.
seq
=
1
;
}
size_t
n
=
0
;
if
(
e
==
EVENT_DISARM
)
{
if
(
++
client
.
second
.
seq
==
10000
)
{
client
.
second
.
seq
=
1
;
}
if
(
e
==
EVENT_DISARM
)
{
auto
xdata
=
makeXData
(
pwd
,
6
);
n
=
context
->
packet
.
make_hb
(
buf
,
sizeof
(
buf
),
client
.
second
.
seq
,
client
.
second
.
acct
,
client
.
second
.
ademco_id
,
0
,
e
,
0
,
xdata
);
}
else
{
...
...
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