From 79a6cd629e9092db76c1694f62d972204b072981 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?= Date: Fri, 18 Apr 2025 09:33:05 +0700 Subject: [PATCH] libmateweather: fix double free --- .../libmateweather/patches/libsoup-3.0.patch | 53 ++++++++++++++++--- srcpkgs/libmateweather/template | 2 +- 2 files changed, 48 insertions(+), 7 deletions(-) diff --git a/srcpkgs/libmateweather/patches/libsoup-3.0.patch b/srcpkgs/libmateweather/patches/libsoup-3.0.patch index 84061ac342d..3737e5c5f68 100644 --- a/srcpkgs/libmateweather/patches/libsoup-3.0.patch +++ b/srcpkgs/libmateweather/patches/libsoup-3.0.patch @@ -1,4 +1,4 @@ -From 97cd9b061ad9b75568af3737f7e4a1dd4bed9c1a Mon Sep 17 00:00:00 2001 +From 52487e56c267328d45f1867cef0e4f4d7e4e6aa7 Mon Sep 17 00:00:00 2001 From: Đoàn Trần Công Danh Date: Mon, 4 Mar 2024 23:47:37 +0700 Subject: [PATCH] Port to libsoup-3.0 @@ -11,12 +11,54 @@ Subject: [PATCH] Port to libsoup-3.0 libmateweather/weather-bom.c | 36 ++++++++----- libmateweather/weather-iwin.c | 37 ++++++++----- libmateweather/weather-met.c | 34 ++++++++---- - libmateweather/weather-metar.c | 57 ++++++++++++++------ + libmateweather/weather-metar.c | 56 ++++++++++++++------ libmateweather/weather-priv.h | 6 ++- libmateweather/weather-wx.c | 53 +++++++++--------- libmateweather/weather.c | 7 +-- - 11 files changed, 157 insertions(+), 93 deletions(-) + 11 files changed, 156 insertions(+), 93 deletions(-) +diff --git a/.build.yml b/.build.yml +index 622db50..024b8f4 100644 +--- a/.build.yml ++++ b/.build.yml +@@ -9,7 +9,7 @@ requires: + - gcc + - git + - gtk3 +- - libsoup ++ - libsoup3 + - make + - mate-common + - tzdata +@@ -27,8 +27,7 @@ requires: + - gtk-doc-tools + - libglib2.0-dev + - libgtk-3-dev +- - libsoup-gnome2.4-dev +- - libsoup2.4-dev ++ - libsoup-3.0-dev + - libxml2-dev + - libxml2-utils + - make +@@ -44,7 +43,7 @@ requires: + - gcc + - git + - gtk3-devel +- - libsoup-devel ++ - libsoup3-devel + - libxml2-devel + - make + - mate-common +@@ -60,8 +59,7 @@ requires: + - gtk-doc-tools + - libglib2.0-dev + - libgtk-3-dev +- - libsoup-gnome2.4-dev +- - libsoup2.4-dev ++ - libsoup-3.0-dev + - libxml2-dev + - libxml2-utils + - make diff --git a/configure.ac b/configure.ac index 133108e..d9fcf9c 100644 --- a/configure.ac @@ -317,7 +359,7 @@ index 164e9f2..7022abb 100644 info->requests_pending++; diff --git a/libmateweather/weather-metar.c b/libmateweather/weather-metar.c -index 7bc24fc..d85188b 100644 +index 7bc24fc..d470822 100644 --- a/libmateweather/weather-metar.c +++ b/libmateweather/weather-metar.c @@ -486,43 +486,60 @@ metar_parse (gchar *metar, WeatherInfo *info) @@ -422,7 +464,7 @@ index 7bc24fc..d85188b 100644 "dataSource", "metars", "requestType", "retrieve", "format", "xml", -@@ -559,7 +577,12 @@ metar_start_open (WeatherInfo *info) +@@ -559,7 +577,11 @@ metar_start_open (WeatherInfo *info) "fields", "raw_text", "stationString", loc->code, NULL); @@ -430,7 +472,6 @@ index 7bc24fc..d85188b 100644 + msg = soup_message_new_from_encoded_form ( + "GET", "https://aviationweather.gov/cgi-bin/data/dataserver.php", + query); -+ g_free(query); + soup_session_send_and_read_async (info->session, msg, G_PRIORITY_DEFAULT, + NULL, metar_finish, info); diff --git a/srcpkgs/libmateweather/template b/srcpkgs/libmateweather/template index 1ed517162fe..9c96e3dcd89 100644 --- a/srcpkgs/libmateweather/template +++ b/srcpkgs/libmateweather/template @@ -1,7 +1,7 @@ # Template file for 'libmateweather' pkgname=libmateweather version=1.28.0 -revision=1 +revision=2 build_style=gnu-configure configure_args="--disable-static --enable-locations-compression --with-zoneinfo-dir=/usr/share/zoneinfo"