8a4939c971
in an arithmetic expression, leading to surprising results when used later with arithmetic expressions of the same precedence as parameter a. This is very old X11 code, copy and pasted to several places over the years. Fixed in 1.9something (which is in mit/external). OK by wiz@. This seems to be the root cause of CVE-2010-1166.
13 lines
383 B
Text
13 lines
383 B
Text
$NetBSD: patch-sf,v 1.1 2011/12/30 09:33:04 is Exp $
|
|
|
|
--- fb/fbpict.c.orig 2009-10-12 02:52:40.000000000 +0000
|
|
+++ fb/fbpict.c
|
|
@@ -37,7 +37,7 @@
|
|
#include "mipict.h"
|
|
#include "fbpict.h"
|
|
|
|
-#define mod(a,b) ((b) == 1 ? 0 : (a) >= 0 ? (a) % (b) : (b) - (-a) % (b))
|
|
+#define mod(a,b) ((b) == 1 ? 0 : (a) >= 0 ? (a) % (b) : (b) - (-(a)) % (b))
|
|
|
|
void
|
|
fbWalkCompositeRegion (CARD8 op,
|