From: Michael Tremer Date: Sat, 21 Jun 2025 11:46:36 +0000 (+0000) Subject: buildservice: Tell the API that we would like to receive JSON X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9e399bc039482160764679adad32242d2790a3eb;p=pakfire.git buildservice: Tell the API that we would like to receive JSON Signed-off-by: Michael Tremer --- diff --git a/src/pakfire/buildservice.c b/src/pakfire/buildservice.c index 179f6109..8b3ec5c7 100644 --- a/src/pakfire/buildservice.c +++ b/src/pakfire/buildservice.c @@ -74,6 +74,11 @@ static int pakfire_buildservice_xfer_create(struct pakfire_xfer** xfer, if (r < 0) goto ERROR; + // Tell the API that we want to receive a JSON response + r = pakfire_xfer_add_header(x, "Accept: application/json"); + if (r < 0) + goto ERROR; + // Success *xfer = pakfire_xfer_ref(x);