On Wed, Oct 19, 2011 at 05:01:08PM -0700, Ping Cheng wrote: > normalizePressure crashes if wcmMaxZ is 0. > > Signed-off-by: Ping Cheng <pi...@wacom.com> > --- > src/wcmCommon.c | 8 ++++---- > 1 files changed, 4 insertions(+), 4 deletions(-) > > diff --git a/src/wcmCommon.c b/src/wcmCommon.c > index c3c8907..08b3283 100644 > --- a/src/wcmCommon.c > +++ b/src/wcmCommon.c > @@ -1168,17 +1168,17 @@ static void commonDispatchDevice(WacomCommonPtr > common, unsigned int channel, > return; > } > > - if (IsPen(priv) || IsTouch(priv)) > + if (IsPen(priv)) > + common->wcmPenInProx = filtered.proximity; > + > + if ((IsPen(priv) || IsTouch(priv)) && common->wcmMaxZ) > { > priv->minPressure = rebasePressure(priv, &filtered); > filtered.pressure = normalizePressure(priv, &filtered); > if (IsPen(priv)) > filtered.buttons = setPressureButton(priv, &filtered); > filtered.pressure = applyPressureCurve(priv,&filtered); > - if (IsPen(priv)) > - common->wcmPenInProx = filtered.proximity; > } > - > else if (IsCursor(priv) && !priv->oldCursorHwProx) > { > /* initial current max distance for Intuos series */ > -- > 1.7.6.4
8a80397..ee6abf7 master -> master thanks. Cheers, Peter ------------------------------------------------------------------------------ The demand for IT networking professionals continues to grow, and the demand for specialized networking skills is growing even more rapidly. Take a complimentary Learning@Cisco Self-Assessment and learn about Cisco certifications, training, and career opportunities. http://p.sf.net/sfu/cisco-dev2dev _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel