From 8041518cf9774da8e9025f87ed0851f141097c22 Mon Sep 17 00:00:00 2001
From: nishi <nishi@d27a3e52-49c5-7645-884c-6793ebffc270>
Date: Tue, 13 Feb 2024 01:33:12 +0000
Subject: [PATCH] Location header

git-svn-id: file:///raid/svn-main/nishi-libw3/trunk@203 d27a3e52-49c5-7645-884c-6793ebffc270
---
 Library/Gemini.c | 6 ++++++
 W3Version.h.p    | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/Library/Gemini.c b/Library/Gemini.c
index 0d6fa82..9a96db5 100644
--- a/Library/Gemini.c
+++ b/Library/Gemini.c
@@ -42,6 +42,12 @@ void __W3_Gemini_Request(struct W3* w3) {
 								void (*func)(struct W3*, char*, char*) = (void (*)(struct W3*, char*, char*))funcptr;
 								func(w3, "Content-Type", meta);
 							}
+						}else if(atoi(code) >= 30 && atoi(code) < 40){
+							void* funcptr = __W3_Get_Event(w3, "header");
+							if(funcptr != NULL) {
+								void (*func)(struct W3*, char*, char*) = (void (*)(struct W3*, char*, char*))funcptr;
+								func(w3, "Location", meta);
+							}
 						}
 					}
 				}else if(!bcode){
diff --git a/W3Version.h.p b/W3Version.h.p
index 9ef884d..723af1d 100644
--- a/W3Version.h.p
+++ b/W3Version.h.p
@@ -6,7 +6,7 @@
 extern "C" {
 #endif
 
-#define LIBW3_VERSION "2.5B" \
+#define LIBW3_VERSION "2.6" \
 SUFFIX
 
 #ifdef __cplusplus
-- 
2.43.0