1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-10-17 22:32:25 +00:00
serenity/Ports/cfunge/patches/0002-Define-MAX-inline-instead-of-using-sys-param.h.patch
2022-05-19 20:17:10 +04:30

25 lines
835 B
Diff

From 8e430a265acf87063fff9b00b18dff91c4a6f073 Mon Sep 17 00:00:00 2001
From: Tobias Christiansen <tobyase@serenityos.org>
Date: Thu, 24 Mar 2022 15:41:48 +0100
Subject: [PATCH 2/4] Define MAX inline instead of using sys/param.h
---
lib/fungestring/funge_str-two-way.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/fungestring/funge_str-two-way.h b/lib/fungestring/funge_str-two-way.h
index 70295f4..a3e0888 100644
--- a/lib/fungestring/funge_str-two-way.h
+++ b/lib/fungestring/funge_str-two-way.h
@@ -53,7 +53,7 @@
#include <limits.h>
#include <stdint.h>
-#include <sys/param.h> /* Defines MAX. */
+#define MAX(a,b) (((a)>(b))?(a):(b))
/* We use the Two-Way string matching algorithm, which guarantees
linear complexity with constant space. Additionally, for long
--
2.36.1