Skip to content

Commit

Permalink
Add logs for server request
Browse files Browse the repository at this point in the history
  • Loading branch information
Ma233 committed Jun 16, 2024
1 parent 5171eb4 commit c10f012
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,12 @@ impl PProxy {
let Ok(Ok(n)) =
timeout(std::time::Duration::from_secs(2), stream.read(&mut buf)).await
else {
warn!("http stream read failed");
break;
};

if n == 0 {
warn!("empty response from http server");
break;
}

Expand Down

0 comments on commit c10f012

Please sign in to comment.