[PATCH xserver 1/2] fix percent options parsing

Simon Thum simon.thum at gmx.de
Mon Feb 7 14:25:46 PST 2011


This allows to specify e.g. 0.5% without rounding to zero.

Signed-off-by: Simon Thum <simon.thum at gmx.de>
---

 All other percent-related functions return double already.

 hw/xfree86/common/xf86Option.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/hw/xfree86/common/xf86Option.c b/hw/xfree86/common/xf86Option.c
index 16c27e5..455cafa 100644
--- a/hw/xfree86/common/xf86Option.c
+++ b/hw/xfree86/common/xf86Option.c
@@ -212,7 +212,7 @@ LookupBoolOption(pointer optlist, const char *name,
int deflt, Bool markUsed)
     return deflt;
 }
 -static int
+static double
 LookupPercentOption(pointer optlist, const char *name, double deflt,
Bool markUsed)
 {
     OptionInfoRec o;
-- 
1.7.3.4



More information about the xorg-devel mailing list