Age | Commit message (Collapse) | Author | Files | Lines |
|
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Not needed since 6cf844ab69926b split out the allocation/manipulation
into the helper function, leaving FindModule just copying the pointer
around, and causing gcc warnings and an unreachable call to free.
Also no longer need to store the combined strlen results in dirlen.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Stop temporarily storing a pointer to a constant literal string
in a char *, just to strdup it a few lines later.
Fixes gcc -Wwrite-strings warnings:
xkbInit.c: In function 'XkbGetRulesDflts':
xkbInit.c:121:38: warning: assignment discards qualifiers from pointer target type
xkbInit.c:123:23: warning: assignment discards qualifiers from pointer target type
xkbInit.c:125:24: warning: assignment discards qualifiers from pointer target type
xkbInit.c:127:25: warning: assignment discards qualifiers from pointer target type
xkbInit.c:129:25: warning: assignment discards qualifiers from pointer target type
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Exposed by recent addition of -Wredundant-decls to default CWARNFLAGS
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Matches what linux_agp already does and prevents gcc from throwing up:
sun_agp.c: In function 'xf86DeallocateGARTMemory':
sun_agp.c:236:40: error: cast to pointer from integer of different size
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Cleans up around 120 warnings from this set
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Silencing more gcc -Wwrite-strings warnings
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Instead of using sprintf to copy a static string to a local buffer,
just to pass it to TryCopyStr, pass the static string to TryCopyStr
directly, as is already done in other parts of this code.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
This batch is the straightforward set - others are more complex and
need more analysis to determine right size to pass.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Found no calls from current driver modules
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Gets rid of duplicate static copy of optionTypeToString by putting
both callers of that helper function in the same source file.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
When we want to print a string, it's okay to just print it.
We don't need to first allocate a buffer 2 bytes bigger than the
string, copy the entire string unmodified to the buffer, print the
buffer, and then leak the buffer (though we AbortDDX 8 lines later,
and then just in case we survived that, call exit as well, so the
leak is short lived, just oh so pointless).
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
"log.c", line 382: warning: assignment type mismatch:
pointer to char "=" pointer to const char
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
The extra "out" pointer to redirect writes to the array isn't needed since
the removal of LBX (commit a9ed5a87902a), and eliminating it allows more
logical use of sizeof(addr) in length-checked strlcpy & snprintf calls to
write to it.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Also removes even more unnecessary use of variable assignment inside
function arguments.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
|
|
Now that MakeAtom takes const char *, so can XIGetKnownProperty.
Clears 71 warnings from gcc -Wwrite-strings of the form:
devices.c:145:5: warning: passing argument 1 of 'XIGetKnownProperty' discards qualifiers from pointer target type
../include/exevents.h:128:23: note: expected 'char *' but argument is of type 'const char *'
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
We just got the string length with strlen, might as well use it
to copy the whole string quickly instead of checking each character
a second time to see if it's 0 or not.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
*cmdname is initialized to NULL earlier in the function, so it's
okay to overwrite it with NULL if strdup fails, don't need that
extra check.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
As long as we're carrying around a compatibility copy in os/strl*.c,
might as well use them.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Linux test code fixed by: Keith Packard <keithp@keithp.com>
|
|
Since the check is for !(compilers that support __builtin_constant_p)
it needs to be !(gcc or new enough Sun cc), but was written as
!(gcc or too old Sun cc).
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Two instances found in the SIOCGIFCONF code for listing network interfaces.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
If configure is generated with xorg-macros 1.16.0 or newer, and
an appropriate memory checking library is found for the platform,
use it when running unit tests. If not, then no harm is done.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
If configure is generated with xorg-macros 1.16 or later, this allows
builders to --enable-unit-test and run the tests other than the xi2
tests which require ld -wrap (and are still wrapped in if HAVE_LD_WRAP
in tests/xi2/Makefile). If an older xorg-macros is used, the existing
behaviour is preserved of requiring ld -wrap for all unit tests, but
no side effects occur, so the minimum xorg-macros version is not raised.
If unit testing is enabled without ld -wrap, then we create a bogus
"xi2-tests" script just to report that we're skipping them.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
We don't ship either one, so don't waste time and make confusing log
entries trying to load them.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
|
|
Include strlcpy.c in the libdmxconfig.a library with the other functions
shared among the xdmx configuration programs.
Also add a #include "os.h" to the scanner.l file that now calls strlcpy
to include the prototype from $(top_srcdir)/include/os.h.
(To be squashed into
http://cgit.freedesktop.org/~alanc/xserver/commit/?id=c19f0ff5223d428f8ad2ab3c563c974c96a521ba
before next PULL request to avoid breaking bisection.)
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
This makes sure it gets distributed
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
https://trac.macports.org/ticket/30927
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
At least one revision of the AAO reports a 190x110mm maximum size but a
451x113mm mode.
X.Org Bug 41141 <https://bugs.freedesktop.org/show_bug.cgi?id=41141>
Signed-off-by: Ross Burton <ross@linux.intel.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
The Resource database is reset upon regeneration and so the dri2 module
needs to re-register its RESTYPE for the drawable or else it will
clobber the next unsuspecting user of the database. Fortunately, DRI2 is
loaded late in the initialisation sequence and was last up until
xf86-video-intel started using the Resource database to track
outstanding swaps...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Tested-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
|
|
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=41211
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=17431
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
|
|
Any pad bytes in replies are written to the client from a zeroed
array. However, record extension tries to incorrectly access the pad
bytes from the end of reply data.
Signed-off-by: Rami Ylimäki <rami.ylimaki@vincit.fi>
Reviewed-by: Erkki Seppälä <erkki.seppala@vincit.fi>
|
|
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Tormod Volden <debian.tormod@gmail.com>
|
|
-Werror=pointer-to-int-cast
memType is a uint64_t on powerpc. Using memType only really makes
sense for *physical* addresses, which can be 64-bit for 32-bit
systems running on 64-bit hardware.
However, unmapVidMem() only deals with *virtual* addresses, which
are guaranteed to fit into an uintptr_t.
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
|
|
245cb8e94fd1599 fixed xf86RotateDestroy() to actually run its teardown
code, causing the Damage object to properly be re-allocated after a
server regeneration. However the block that does that still thinks the
Rotate layer BlockHandler is wrapped from the last generation, meaning
the shadow pixmap is never re-allocated and the Damage object is never
re-registered, causing a blank screen, and potentially a driver crash
on the next teardown after the server asks it to free a 0x0 Pixmap.
Signed-off-by: Pierre-Loup A. Griffais <pgriffais@nvidia.com>
Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
xselinux_ext.c: In function 'SELinuxSendItemsToClient':
xselinux_ext.c:340:16: warning: unused variable 'n' [-Wunused-variable]
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
|
|
xselinux_ext.c: In function 'SELinuxSendItemsToClient':
xselinux_ext.c:340:16: warning: unused variable 'n' [-Wunused-variable]
xselinux_ext.c: In function 'SProcSELinuxQueryVersion':
xselinux_ext.c:532:62: error: call to 'wrong_size' declared with attribute
error: wrong sized variable passed to swap
xselinux_ext.c:533:62: error: call to 'wrong_size' declared with attribute
error: wrong sized variable passed to swap
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
|
|
Wherever it's obvious which device we need (keyboard or pointer), use
GetMaster() instead of GetPairedDevice(). It is more reliable in actually
getting the device type we want.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
|