Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
leap
vpnweb
Commits
7bb4eb2e
Commit
7bb4eb2e
authored
Feb 11, 2020
by
Kali Kaneko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[docs] comment on unsafe method
parent
3de10718
Pipeline
#34512
passed with stages
in 2 minutes and 40 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
pkg/auth/sip2/client.go
pkg/auth/sip2/client.go
+3
-2
No files found.
pkg/auth/sip2/client.go
View file @
7bb4eb2e
...
...
@@ -61,10 +61,10 @@ func newClient(host, port, location string) sipClient {
return
c
}
// starts a dispatcher goroutine that ensures that all sip requests are serialized
func
(
c
*
sipClient
)
startDispatcher
()
{
go
func
()
{
for
{
req
:=
<-
c
.
reqQueue
for
req
:=
range
c
.
reqQueue
{
resp
,
err
:=
c
.
handleRequest
(
req
.
msg
)
req
.
respChan
<-
response
{
resp
,
err
}
}
...
...
@@ -102,6 +102,7 @@ func (c *sipClient) sendRequest(msg string) (string, error) {
return
resp
.
msg
,
resp
.
err
}
// handleRequest should not be used directly: dipatcher should be the only caller. use sendRequest instead.
func
(
c
*
sipClient
)
handleRequest
(
msg
string
)
(
string
,
error
)
{
err
:=
telnetSend
(
c
.
conn
,
msg
)
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