4667bb6be4
definition of the abs() macro. Based on a suggestion by Roland Illig.
24 lines
650 B
Text
24 lines
650 B
Text
$NetBSD: patch-aj,v 1.2 2005/02/17 23:16:44 tron Exp $
|
|
|
|
--- Xvnc/programs/Xserver/include/misc.h.orig 1996-12-23 07:09:29.000000000 +0000
|
|
+++ Xvnc/programs/Xserver/include/misc.h 2005-02-17 23:05:46.000000000 +0000
|
|
@@ -83,6 +83,10 @@
|
|
#include <X11/Xmd.h>
|
|
#include <X11/X.h>
|
|
|
|
+#ifdef __NetBSD__
|
|
+#include <stdlib.h>
|
|
+#endif
|
|
+
|
|
#ifndef NULL
|
|
#ifndef X_NOT_STDC_ENV
|
|
#include <stddef.h>
|
|
@@ -159,7 +166,7 @@
|
|
#define min(a, b) (((a) < (b)) ? (a) : (b))
|
|
#define max(a, b) (((a) > (b)) ? (a) : (b))
|
|
#if !defined(AMOEBA) && !defined(__EMX__)
|
|
-#ifndef abs
|
|
+#if !defined(abs)
|
|
#define abs(a) ((a) > 0 ? (a) : -(a))
|
|
#endif
|
|
#else /* AMOEBA || __EMX__ */
|