uhttpmock: add HTTP/2 support
This commit is contained in:
parent
60da64cf1a
commit
f9bd868607
2 changed files with 38 additions and 1 deletions
37
srcpkgs/uhttpmock/patches/add-http2-support.patch
Normal file
37
srcpkgs/uhttpmock/patches/add-http2-support.patch
Normal file
|
@ -0,0 +1,37 @@
|
||||||
|
From 46e86c50044e07c7427233495c0c21adfdb47891 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Jan-Michael Brummer <jan-michael.brummer1@volkswagen.de>
|
||||||
|
Date: Fri, 8 Mar 2024 19:58:43 +0100
|
||||||
|
Subject: [PATCH] Add HTTP/2 support
|
||||||
|
|
||||||
|
---
|
||||||
|
libuhttpmock/uhm-server.c | 6 ++++++
|
||||||
|
1 file changed, 6 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/libuhttpmock/uhm-server.c b/libuhttpmock/uhm-server.c
|
||||||
|
index 4451a91..da5d3a5 100644
|
||||||
|
--- a/libuhttpmock/uhm-server.c
|
||||||
|
+++ b/libuhttpmock/uhm-server.c
|
||||||
|
@@ -873,6 +873,9 @@ trace_to_soup_message (const gchar *trace, GUri *base_uri)
|
||||||
|
} else if (strncmp (trace, "HTTP/1.0", strlen ("HTTP/1.0")) == 0) {
|
||||||
|
http_version = SOUP_HTTP_1_0;
|
||||||
|
trace += strlen ("HTTP/1.0");
|
||||||
|
+ } else if (strncmp (trace, "HTTP/2", strlen ("HTTP/2")) == 0) {
|
||||||
|
+ http_version = SOUP_HTTP_2_0;
|
||||||
|
+ trace += strlen ("HTTP/2");
|
||||||
|
} else {
|
||||||
|
g_warning ("Unrecognised HTTP version ‘%s’.", trace);
|
||||||
|
http_version = SOUP_HTTP_1_1;
|
||||||
|
@@ -914,6 +917,9 @@ trace_to_soup_message (const gchar *trace, GUri *base_uri)
|
||||||
|
} else if (strncmp (trace, "HTTP/1.0", strlen ("HTTP/1.0")) == 0) {
|
||||||
|
http_version = SOUP_HTTP_1_0;
|
||||||
|
trace += strlen ("HTTP/1.0");
|
||||||
|
+ } else if (strncmp (trace, "HTTP/2", strlen ("HTTP/2")) == 0) {
|
||||||
|
+ http_version = SOUP_HTTP_2_0;
|
||||||
|
+ trace += strlen ("HTTP/2");
|
||||||
|
} else {
|
||||||
|
g_warning ("Unrecognised HTTP version ‘%s’.", trace);
|
||||||
|
}
|
||||||
|
--
|
||||||
|
GitLab
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# Template file for 'uhttpmock'
|
# Template file for 'uhttpmock'
|
||||||
pkgname=uhttpmock
|
pkgname=uhttpmock
|
||||||
version=0.10.0
|
version=0.10.0
|
||||||
revision=1
|
revision=2
|
||||||
build_style=meson
|
build_style=meson
|
||||||
build_helper="gir"
|
build_helper="gir"
|
||||||
configure_args="$(vopt_bool gtk_doc gtk_doc)"
|
configure_args="$(vopt_bool gtk_doc gtk_doc)"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue