Skip to content

Commit

Permalink
Merge pull request #454 from mstreeter10/adapter-fix
Browse files Browse the repository at this point in the history
udb: socket reading fix
  • Loading branch information
Jafaral authored May 3, 2024
2 parents 8399ced + 10e961b commit 9cd4bbe
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions uni/udb/adapter.icn
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ class Adapter(
method process_request(request_json)
local request_body, request_seq, request_command, request_arguments, response_body

request_body := jtou(request_json)
request_body := jtou(request_json) | fail

request_seq := request_body["seq"]
request_command := request_body["command"]
Expand Down Expand Up @@ -175,8 +175,12 @@ class Adapter(
}
else {
request_body := move(len)
msg := tab(0)
}
until *request_body = len do {
(*select(sock, 5000) ~= 0) | break
request_body ||:= ready(sock, len)
}
msg := tab(0)
}
suspend request_body
}
Expand Down

0 comments on commit 9cd4bbe

Please sign in to comment.