serenity/Ports/libpuffy/patches/0001-Add-a-definition-for-llabs.patch

28 lines
699 B
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Gunnar Beutner <gbeutner@serenityos.org>
Date: Sat, 1 May 2021 22:43:05 +0200
Subject: [PATCH] Add a definition for llabs
---
fmt_scaled.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fmt_scaled.c b/fmt_scaled.c
index 6ad314e..6e68356 100644
--- a/fmt_scaled.c
+++ b/fmt_scaled.c
@@ -207,11 +207,13 @@ scan_scaled(char *scaled, long long *result)
return -1;
}
+#ifndef __serenity__
static long long
llabs(long long j)
{
return (j < 0 ? -j : j);
}
+#endif
/* Format the given "number" into human-readable form in "result".
* Result must point to an allocated buffer of length FMT_SCALED_STRSIZE.