File pcsx2_rapidyaml-fix.patch of Package pcsx2-magicgate-patched

From e5d5559ff40d798327d524204016f1a4d0da22e5 Mon Sep 17 00:00:00 2001
From: ahmedmoselhi <ahmedmoselhi55@gmail.com>
Date: Tue, 4 Apr 2023 21:54:57 +0200
Subject: [PATCH] pcsx2_rapidyaml-fix

---
 pcsx2/GameDatabase.cpp | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/pcsx2/GameDatabase.cpp b/pcsx2/GameDatabase.cpp
index 26f6d0f19..c3e9d68a2 100644
--- a/pcsx2/GameDatabase.cpp
+++ b/pcsx2/GameDatabase.cpp
@@ -156,7 +156,7 @@ void GameDatabase::parseAndInsert(const std::string_view& serial, const c4::yml:
 	// Validate game fixes, invalid ones will be dropped!
 	if (node.has_child("gameFixes") && node["gameFixes"].has_children())
 	{
-		for (const ryml::NodeRef& n : node["gameFixes"].children())
+		for (const ryml::ConstNodeRef& n : node["gameFixes"].children())
 		{
 			bool fixValidated = false;
 			auto fix = std::string(n.val().str, n.val().len);
@@ -187,7 +187,7 @@ void GameDatabase::parseAndInsert(const std::string_view& serial, const c4::yml:
 	// Validate speed hacks, invalid ones will be dropped!
 	if (node.has_child("speedHacks") && node["speedHacks"].has_children())
 	{
-		for (const ryml::NodeRef& n : node["speedHacks"].children())
+		for (const ryml::ConstNodeRef& n : node["speedHacks"].children())
 		{
 			bool speedHackValidated = false;
 			auto speedHack = std::string(n.key().str, n.key().len);
@@ -217,7 +217,7 @@ void GameDatabase::parseAndInsert(const std::string_view& serial, const c4::yml:
 
 	if (node.has_child("gsHWFixes"))
 	{
-		for (const ryml::NodeRef& n : node["gsHWFixes"].children())
+		for (const ryml::ConstNodeRef& n : node["gsHWFixes"].children())
 		{
 			const std::string_view id_name(n.key().data(), n.key().size());
 			std::optional<GameDatabaseSchema::GSHWFixId> id = GameDatabaseSchema::parseHWFixName(id_name);
@@ -238,7 +238,7 @@ void GameDatabase::parseAndInsert(const std::string_view& serial, const c4::yml:
 	// - currently they are used as a '\n' delimited string in the app
 	if (node.has_child("memcardFilters") && node["memcardFilters"].has_children())
 	{
-		for (const ryml::NodeRef& n : node["memcardFilters"].children())
+		for (const ryml::ConstNodeRef& n : node["memcardFilters"].children())
 		{
 			auto memcardFilter = std::string(n.val().str, n.val().len);
 			gameEntry.memcardFilters.emplace_back(std::move(memcardFilter));
@@ -248,7 +248,7 @@ void GameDatabase::parseAndInsert(const std::string_view& serial, const c4::yml:
 	// Game Patches
 	if (node.has_child("patches") && node["patches"].has_children())
 	{
-		for (const ryml::NodeRef& n : node["patches"].children())
+		for (const ryml::ConstNodeRef& n : node["patches"].children())
 		{
 			// use a crc of 0 for default patches
 			const std::string_view crc_str(n.key().str, n.key().len);
-- 
2.40.0

openSUSE Build Service is sponsored by