Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Joshua
wendelin.core
Commits
6d4007b2
Commit
6d4007b2
authored
Mar 09, 2020
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
f8d30e17
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
wcfs/client/wcfs_watchlink.cpp
wcfs/client/wcfs_watchlink.cpp
+4
-3
No files found.
wcfs/client/wcfs_watchlink.cpp
View file @
6d4007b2
...
...
@@ -420,6 +420,10 @@ tuple<string, error> _WatchLink::_readline() {
}
nl_searchfrom
=
wlink
.
_rxbuf
.
length
();
// limit line length to avoid DoS
if
(
wlink
.
_rxbuf
.
length
()
>
128
)
return
make_tuple
(
""
,
fmt
::
errorf
(
"line is too long"
));
int
n
;
error
err
;
//trace("\t_readline -> read ...\n");
...
...
@@ -427,9 +431,6 @@ tuple<string, error> _WatchLink::_readline() {
//trace("\t_readline -> read: n=%d err='%s'\n", n, v(err));
if
(
n
>
0
)
{
wlink
.
_rxbuf
+=
string
(
buf
,
n
);
// limit line length to avoid DoS
if
(
wlink
.
_rxbuf
.
length
()
>
128
)
// XXX limit arbitrary
return
make_tuple
(
""
,
fmt
::
errorf
(
"line is too long"
));
continue
;
}
if
(
err
==
nil
)
...
...
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