Skip to content

Commit

Permalink
http: check ship for scry at now
Browse files Browse the repository at this point in the history
  • Loading branch information
midden-fabler committed Aug 7, 2024
1 parent bee8af3 commit 88f92ee
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions pkg/vere/io/http.c
Original file line number Diff line number Diff line change
Expand Up @@ -963,8 +963,19 @@ _http_req_dispatch(u3_hreq* req_u, u3_noun req)
// peek or respond from cache
//
if ( c3y == req_u->peq_u->las_o ) {
u3_pier_peek_last(htd_u->car_u.pir_u, gang, c3__ex,
u3k(bem.des), spur, req_u->peq_u, _http_scry_cb);
u3_noun our = u3dc("scot", 'p', u3i_chubs(2, htd_u->car_u.pir_u->who_d));
if ( our == bem.who ) {
u3_pier_peek_last(htd_u->car_u.pir_u, gang, c3__ex,
u3k(bem.des), spur, req_u->peq_u, _http_scry_cb);
}
else {
c3_c* msg_c = "bad request";
h2o_send_error_generic(req_u->rec_u, 400, msg_c, msg_c, 0);
u3z(gang);
u3z(spur);
u3z(req_u->peq_u->pax);
}
u3z(our);
}
else {
u3_noun bam = u3nq(u3k(bem.who), u3k(bem.des), u3k(bem.cas), spur);
Expand Down

0 comments on commit 88f92ee

Please sign in to comment.