Work on setuid/setgid, add raw-data-parser for the brmbar disaster.

This commit is contained in:
Dominik Pantůček 2025-04-13 10:21:46 +02:00
parent ae5b9e2775
commit 8bd46721aa
4 changed files with 93 additions and 6 deletions

View file

@ -36,7 +36,8 @@
(chicken format)
bar-db
json
(chicken port))
(chicken port)
(chicken base))
(define-syntax try-match-lambda1
(syntax-rules ()
@ -82,7 +83,7 @@
(json-write
(list->vector alst)))))
(define-try-match (account-barcode-info "barcode" (barcode string->number))
(define-try-match (account-barcode-info "barcode" (barcode identity))
(send-response
#:body (alist->json-string
`((amount . ,(bd-barcode-lookup barcode))))))