Age | Commit message (Collapse) | Author | Files | Lines |
|
If the reported number of properties is too large, the calculations
to allocate memory for them may overflow, leaving us returning less
memory to the caller than implied by the value written to *nitems.
(Same as reported against libX11 XGetWindowProperty by Ilja Van Sprundel)
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
If the reported number of properties is too large, the calculations
to allocate memory for them may overflow, leaving us returning less
memory to the caller than implied by the value written to *nitems.
(Same as reported against libX11 XGetWindowProperty by Ilja Van Sprundel)
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Same problem as XRRQueryOutputProperty() that it was cloned from
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
rep.length is a CARD32, while rbytes was a signed int, so
rbytes = sizeof (XRRPropertyInfo) + rep.length * sizeof (long);
could result in integer overflow, leading to an undersized malloc
and reading data off the connection and writing it past the end of
the allocated buffer.
Reported-by: Ilja Van Sprundel <ivansprundel@ioactive.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
rep.length is a CARD32, so rep.length << 2 could overflow in 32-bit builds
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Excerpt https://lists.gnu.org/archive/html/automake/2012-12/msg00038.html
- Support for the long-deprecated INCLUDES variable will be removed
altogether in Automake 1.14. The AM_CPPFLAGS variable should be
used instead.
This variable was deprecated in Automake releases prior to 1.10, which is
the current minimum level required to build X.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Fixes compiler warnings when building app/xrandr:
xrandr.c: In function ‘crtc_set_transform’:
xrandr.c:1459:9: warning: passing argument 4 of ‘XRRSetCrtcTransform’ discards qualifiers from pointer target type
X11/extensions/Xrandr.h:419:1: note: expected ‘char *’ but argument is of type ‘const char *’
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
|
|
This adds the client side libXrandr support for randr 1.4,
and provider objects.
Signed-off-by: Dave Airlie <airlied@redhat.com>
|
|
Even though it probably makes more sense to just strlen() the name, for
some reason there's a nameLen field in XRROutputInfo, so might as well
actually fill it in.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reported-by: Leif Middelschulte <leif.middelschulte@gmail.com>
|
|
Performed with: find * -type f | xargs perl -i -p -e 's{[ \t]+$}{}'
git diff -w & git diff -b show no diffs from this change
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Signed-off-by: Fernando Carrijo <fcarrijo@yahoo.com.br>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
As mentioned in bugzilla ticket 28150.
Calling '_XRRValidateCache' with 'improper' arguments results in a SEGV.
This patch adds a parameter validation to the mentioned function.
Signed-off-by: Leif Middelschulte <leif.middelschulte@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Compiler warning flags should be explicitly set in the makefile
rather than being merged with other packages compiler flags.
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
|
|
We didn't treat _XReply failure as fatal. Parsing an xError as a gamma
ramp reply doesn't work that often.
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
|
|
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
|
|
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
|
|
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
|
|
Using X_RRGetOutputProperty does not yield success here.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
Warning corrections are either unused symbols or using an
integer as a pointer (generated by sparse).
|
|
* XRRExtensionInfo can be static
* XRRExtensionName is not called XrandrExtensionName
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
f176b2bda103f6f38aabab8207f47a02cc797659 fixed XRRWireToEvent, but
XRREventToWire had the same bug.
Signed-off-by: Julien Cristau <jcristau@debian.org>
|
|
Conflicts:
src/Xrandr.c
|
|
|
|
|
|
Leaving this uninitialized isn't very helpful, and can cause segfaults.
|
|
|
|
|
|
|
|
These parameters are not treated as input. Rename them to make the inner
workings slightly more obvious.
X.Org Bug 14511 <http://bugs.freedesktop.org/show_bug.cgi?id=14511>
|
|
It is easier, and potentially more precise, to compute the inverse in the
server where everything can eventually be kept in floating point form.
|
|
XRRGetCrtcTransform now returns a giant struct containing all of the
transform and filter data.
XRRSetCrtcTransform now accepts filter parameters.
|
|
|
|
XExtensionInfo, XRRExtensionName, XRRFindDisplay, _XRRHasRates and
_XRRVersionHandler are internal to libXrandr. Don't export them.
|
|
CrtcChange events were getting the source 'height' value stored in the
'width' target in both conversion directions.
|
|
|
|
|
|
Be consistent in variable usage:
nbytes = network byte length.
rbytes = memory byte length.
nbytesRead = actual network bytes read.
Malloc rbytes data to pass to _XRead*, but use nbytes as the
amount of data to read (yes, this is insane, welcome to Xlib).
Some of this patch is semi-gratuitous, but the goal is to be consistent
everywhere.
|
|
Previously, XRRQueryOutputProperty90 would return an uninitialized pointer if
num_values was 0.
|
|
XRRFindDisplay must make extension requests that use LockDisplay, so don't
call it with the display locked, instead pass the info around to the
internal functions that were calling it themselves, having acquired the info
before the outer LockDisplay is called.
|
|
XRRGetCrtcInfo was not moving the rotations value from the wire reply
structure to the XRRCrtcInfo being returned, leaving the value uninitialized.
|
|
|
|
They build. More testing seems indicated.
|