mirror of
https://github.com/bolkedebruin/rdpgw.git
synced 2025-08-17 22:13:50 +02:00
Use context
This commit is contained in:
parent
5de3767e70
commit
39c73fc8fc
3 changed files with 21 additions and 20 deletions
|
@ -2,6 +2,7 @@ package protocol
|
|||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"encoding/binary"
|
||||
"errors"
|
||||
"github.com/bolkedebruin/rdpgw/transport"
|
||||
|
@ -71,7 +72,7 @@ func NewHandler(s *SessionInfo, conf *HandlerConf) *Handler {
|
|||
|
||||
const tunnelId = 10
|
||||
|
||||
func (h *Handler) Process() error {
|
||||
func (h *Handler) Process(ctx context.Context) error {
|
||||
for {
|
||||
pt, sz, pkt, err := h.ReadMessage()
|
||||
if err != nil {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue