Commit Graph

309 Commits

Author SHA1 Message Date
Tiago Vignatti
2a806d7fa3 os: remove unused -cursor option
Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2009-08-28 16:05:04 +03:00
Adam Jackson
0b131a5cd9 linux: Yet more malloc() avoidance for backtrace()
Turns out, there's an initializer at the top of backtrace() that (on
some arches) calls dlopen().  dlopen(), unsurprisingly, calls malloc().
So, call backtrace() early in signal handler setup so we can later
safely call it from the signal handler itself.
2009-08-20 15:43:55 -04:00
Adam Jackson
eb031d4013 linux: hand-roll a backtrace printer instead of using backtrace_symbols
Why?  Because backtrace_symbols calls malloc, which you can't do from a
signal handler.  Face?  Palm.
2009-08-19 15:42:34 -04:00
Jesse Adkins
75b9383d8a xserver doesn't stop all connections to localhost
X.Org Bugzilla #23329: http://bugs.freedesktop.org/show_bug.cgi?id=23329
Patch #28648: http://bugs.freedesktop.org/attachment.cgi?id=28648

I noticed in xserver at os/access.c that xorg tries to stop connections
to localhost by checking against the address 127.0.0.1.  However, RFC
3330 defines the localhost network as 127.0.0.0/8.  This means that any
IPv4 address that starts with 127 is just another name for localhost.
2009-08-18 21:13:40 -07:00
Paul Bender
736f2d6472 Bug 16832: XDMCP related build error when --disable-xdmcp is used
X.Org Bugzilla #16832: http://bugs.freedesktop.org/show_bug.cgi?id=16832
Patch #27279: http://bugs.freedesktop.org/attachment.cgi?id=27279
2009-08-03 20:58:37 -07:00
Peter Hutterer
d3f6b43a24 Update to xextproto 7.0.99.1.
xextproto had Xlib client headers moved into libXext.
Protocol header files are named fooproto.h, header files with constants
foo.h or fooconst.h where foo.h was already in use for client-side headers.
2009-07-15 17:00:05 +10:00
Peter Hutterer
1d6b71b8d0 os: switch to byte counting functions
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-07-14 10:14:01 +10:00
Alan Coopersmith
75c51c67b3 Clarify use of and need for mffs vs. ffs
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-06-18 09:49:19 -07:00
Daniel Stone
f534e6bea1 OS: Fix compile warnings
It's a marvel the sigaction() ever actually worked.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2009-06-11 03:55:57 +10:00
Peter Hutterer
d7aef3f663 Merge branch 'master' into xi2
Conflicts:
	Xext/geext.c
	Xi/chdevcur.c
	Xi/extgrbdev.c
	Xi/xiproperty.c
	configure.ac
	dix/ptrveloc.c
	hw/xfree86/common/xf86Config.c
	mi/mipointer.h
	test/input.c
	xkb/xkb.c
2009-05-28 17:20:58 +10:00
Peter Hutterer
4a36db6077 os: fix compiler warning "too few arguments to format"
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-05-22 15:44:58 +10:00
Adam Jackson
c66cf7b64c Update several of my and/or Red Hat's licenses to standard form. 2009-05-14 07:02:44 -04:00
Simon Farnsworth
707af5f8c5 Make the cursor completely optional
For embedded use, it's convenient to be able to disable the cursor
completely, without having to audit and fix up all your third-party
code (e.g. Mozilla Firefox).

Add -nocursor and -cursor server options to enable and disable the
cursor. The default is still -cursor, but embedded users can run the
server with -nocursor to hide the cursor regardless of what
application developers do.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-28 10:43:53 +10:00
Peter Hutterer
0e0642ee94 os: don't malloc memory in LogVMessageVerb.
LogVWrite is limited to a buffer size of 1024, so we don't loose anything here
by truncating. This way we can use LogVMessageVerb (and xf86Msg and friends)
during signal handlers with the normal message types.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-19 22:20:18 +10:00
Adam Jackson
0eb19f9437 xdmcp: Don't crash on X -query with more than 255 IP addresses. (#20675)
You could be more clever than this, but the wire protocol says this
really is an array of not more than 255 ARRAY8, so it's not just a
matter of changing the types.
2009-04-14 10:57:19 -04:00
Alan Coopersmith
98f4179156 Use RTLD_DI_SETSIGNAL to catch runtime dynamic loader errors and clean up
Based on fix for Sun bug 6813925: Xorg needs to catch ld.so.1 failure
 so it can close down devices cleanly
<http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6813925>

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-09 17:10:12 -07:00
Alan Coopersmith
a0b6a363dc Lift fatal signal handlers from DDX'es up to a common DIX implementation
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-09 17:10:12 -07:00
Adam Jackson
843166b033 os: signal handlers return void. 2009-04-06 11:05:17 -04:00
Adam Jackson
aa6fbc2a36 Remove some OS/2 leftovers. 2009-04-06 10:58:47 -04:00
Adam Jackson
cbb165ab88 os: Remove the useless -x option 2009-04-03 18:34:45 -04:00
Adam Jackson
c1cf36ee29 DPMS: Simplify command line parsing 2009-04-03 18:22:20 -04:00
Tomas Carnecky
62183a06e5 Remove two unused defines in C files
These two defines were defined in C files but not used anywhere:

  dix/window.c      #define DeviceEventMasks (KeyPressMask | [...]
  os/connection.c   #define MAXFD 500

Signed-off-by: Tomas Carnecky <tom@dbservice.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-03-23 16:06:34 +10:00
Alan Coopersmith
eba3bab71f Remove #ifdef macII code left over from ancient A/UX 3.0 support
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-03-05 15:09:28 -08:00
Adam Jackson
132b464d73 Remove a bunch of useless casts.
We've had void * for twenty years now people let's try to act like we
know how it works.
2009-01-22 02:11:16 -05:00
Daniel Stone
40877c6680 XKB: Make XKB mandatory
No more #ifdef XKB, because you can't disable the build, and no more
noXkbExtension either.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-01-22 15:06:25 +11:00
Jon TURNEY
656f92e247 Cygwin/X: should also use GetTickCount(), just like Xming
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2009-01-19 14:46:48 +00:00
Julien Cristau
63ff7d236f os: don't mix declarations and code 2009-01-11 08:54:13 +01:00
Julien Cristau
f43a3c61ab os: backtrace() returns int, not size_t 2009-01-11 08:54:13 +01:00
Julien Cristau
5321ae76cf os: ANSI cleanups 2009-01-11 08:54:12 +01:00
Francis Giraldeau
d61e902aab Don't log audit messages when -audit 0 specified
make the auditTrailLevel check more general and don't log when not
using DTRACE and -audit 0 is set.
2008-12-17 09:49:39 +02:00
Colin Guthrie
6d8ea5104c Fix compilation with -Werror=format-security 2008-12-16 17:44:27 -05:00
Peter Hutterer
cb95642dc8 Remove #define NEED_EVENTS and NEED_REPLIES
A grep on xorg/* revealed there's no consumer of this define.

Quote Alan Coopersmith:
"The consumer was in past versions of the headers now located
in proto/x11proto - for instance, in X11R6.0's xc/include/Xproto.h,
all the event definitions were only available if NEED_EVENTS were
defined, and all the reply definitions required NEED_REPLIES.

Looks like Xproto.h dropped them by X11R6.3, which didn't have
the #ifdef's anymore, so these are truly ancient now."

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2008-12-12 11:43:32 +10:00
Paulo Cesar Pereira de Andrade
49f77fff14 Rework symbol visibility for easier maintenance
Save in a few special cases, _X_EXPORT should not be used in C source
files. Instead, it should be used in headers, and the proper C source
include that header. Some special cases are symbols that need to be
shared between modules, but not expected to be used by external drivers,
and symbols that are accessible via LoaderSymbol/dlopen.

  This patch also adds conditionally some new sdk header files, depending
on extensions enabled. These files were added to match pattern for
other extensions/modules, that is, have the headers "deciding" symbol
visibility in the sdk. These headers are:
o Xext/panoramiXsrv.h, Xext/panoramiX.h
o fbpict.h (unconditionally)
o vidmodeproc.h
o mioverlay.h (unconditionally, used only by xaa)
o xfixes.h (unconditionally, symbols required by dri2)

  LoaderSymbol and similar functions now don't have different prototypes,
in loaderProcs.h and xf86Module.h, so that both headers can be included,
without the need of defining IN_LOADER.

  xf86NewInputDevice() device prototype readded to xf86Xinput.h, but
not exported (and with a comment about it).
2008-12-03 05:43:34 -02:00
Paulo Cesar Pereira de Andrade
180bad8477 Add visibility flags to XSERVER_CFLAGS.
This is done to actually change DIX_CFLAGS, as not all "modules" use
XORG_CFLAGS.
  Also export the symbols that are required by other modules after
the change.
2008-12-02 02:50:45 -02:00
Paulo Cesar Pereira de Andrade
d6cbd4511e Export symbols defined in the sdk.
This is the biggest "visibility" patch. Instead of doing a "export"
symbol on demand, export everything in the sdk, so that if some module
fails due to an unresolved symbol, it is because it is using a symbol
not in the sdk.

  Most exported symbols shouldn't really be made visible, neither
advertised in the sdk, as they are only used by a single shared object.

  Symbols in the sdk (or referenced in sdk macros), but not defined
anywhere include:
XkbBuildCoreState()
XkbInitialMap
XkbXIUnsupported
XkbCheckActionVMods()
XkbSendCompatNotify()
XkbDDXFakePointerButton()
XkbDDXApplyConfig()
_XkbStrCaseCmp()
_XkbErrMessages[]
_XkbErrCode
_XkbErrLocation
_XkbErrData
XkbAccessXDetailText()
XkbNKNDetailMaskText()
XkbLookupGroupAndLevel()
XkbInitAtoms()
XkbGetOrderedDrawables()
XkbFreeOrderedDrawables()
XkbConvertXkbComponents()
XkbWriteXKBSemantics()
XkbWriteXKBLayout()
XkbWriteXKBKeymap()
XkbWriteXKBFile()
XkbWriteCFile()
XkbWriteXKMFile()
XkbWriteToServer()
XkbMergeFile()
XkmFindTOCEntry()
XkmReadFileSection()
XkmReadFileSectionName()
InitExtInput()
xf86CheckButton()
xf86SwitchCoreDevice()
RamDacSetGamma()
RamDacRestoreDACValues()
xf86Bpp
xf86ConfigPix24
xf86MouseCflags[]
xf86SupportedMouseTypes[]
xf86NumMouseTypes
xf86ChangeBusIndex()
xf86EntityEnter()
xf86EntityLeave()
xf86WrapperInit()
xf86RingBell()
xf86findOptionBoolean()
xf86debugListOptions()
LoadSubModuleLocal()
LoaderSymbolLocal()
getInt10Rec()
xf86CurrentScreen
xf86ReallocatePciResources()
xf86NewSerialNumber()
xf86RandRSetInitialMode()
fbCompositeSolidMask_nx1xn
fbCompositeSolidMask_nx8888x0565C
fbCompositeSolidMask_nx8888x8888C
fbCompositeSolidMask_nx8x0565
fbCompositeSolidMask_nx8x0888
fbCompositeSolidMask_nx8x8888
fbCompositeSrc_0565x0565
fbCompositeSrc_8888x0565
fbCompositeSrc_8888x0888
fbCompositeSrc_8888x8888
fbCompositeSrcAdd_1000x1000
fbCompositeSrcAdd_8000x8000
fbCompositeSrcAdd_8888x8888
fbGeneration
fbIn
fbOver
fbOver24
fbOverlayGeneration
fbRasterizeEdges
fbRestoreAreas
fbSaveAreas
composeFunctions
VBEBuildVbeModeList()
VBECalcVbeModeIndex()
TIramdac3030CalculateMNPForClock()
shadowBufPtr
shadowFindBuf()
miRRGetScreenInfo()
RRSetScreenConfig()
RRModePruneUnused()
PixmanImageFromPicture()
extern int miPointerGetMotionEvents()
miClipPicture()
miRasterizeTriangle()
fbPush1toN()
fbInitializeBackingStore()
ddxBeforeReset()
SetupSprite()
InitSprite()
DGADeliverEvent()

  SPECIAL CASES
o defined as _X_INTERNAL
	xf86NewInputDevice()
o defined as static
	fbGCPrivateKey
	fbOverlayScreenPrivateKey
	fbScreenPrivateKey
	fbWinPrivateKey
o defined in libXfont.so, but declared in xorg/dixfont.h
	GetGlyphs()
	QueryGlyphExtents()
	QueryTextExtents()
	ParseGlyphCachingMode()
	InitGlyphCaching()
	SetGlyphCachingMode()
2008-11-29 23:56:06 -02:00
Paulo Cesar Pereira de Andrade
74e2669103 Export symbols also defined in libXfont.
libXfont has stubs for these symbols, so, when compiling with hidden
symbols by default, these symbols must be visible in the X Server, or
the stubs in libXfont will be used.
2008-11-27 04:33:44 -02:00
Jeremy Huddleston
e917806fc5 os/connection: TRANS_NOXAUTH bit comparison brainfart fix.
https://bugs.freedesktop.org/show_bug.cgi?id=18524
2008-11-14 10:57:22 -08:00
Alan Coopersmith
c9051b684b Use OsSignal in Popen/Pclose to avoid SysV signal() stupidity 2008-11-05 18:25:57 -08:00
Daniel Stone
f4036f6ace Remove XEvIE
It's unmaintained and has been broken for quite a while; MPX finally
smashed it completely.

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
2008-11-04 16:01:07 +10:30
Daniel Stone
889a8dc02b Xi: XINPUT has been mandatory for ages
Ditch all #ifdef XINPUT, since it's always built.

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
2008-11-04 16:01:07 +10:30
Julien Cristau
5244690a5e Add prototypes for strlcpy/strlcat 2008-10-26 11:44:57 +01:00
Adam Jackson
40f9b6bf0d Argh, macros. 2008-10-23 17:37:46 -04:00
Adam Jackson
0b69526217 Change some #define foo() -> static void foo() 2008-10-23 15:01:58 -04:00
Matthieu Herrb
d72cd753b9 Close well known connections in ServerAbort() 2008-10-21 22:36:21 +02:00
Adam Jackson
94ed0ba1b5 Move xorg_backtrace() up to the OS level so we can call it from DIX. 2008-10-10 16:28:10 -04:00
Jeremy Huddleston
6dbfca571f Depend on xtrans >= 1.2.2 for TRANS_NOXAUTH 2008-10-07 10:07:03 -07:00
Adam Jackson
0ce61e21d6 Remove the Must_have_memory hack.
Also remove an astonishing amount of misunderstanding of how casts work.
2008-10-03 17:51:19 -04:00
Adam Jackson
e6b1c1fada const cleanup 2008-10-03 17:51:19 -04:00
Adam Jackson
fe616f9230 Drop the never-called SkippedRequestCallback list. 2008-10-03 17:51:19 -04:00
Adam Jackson
31136b9467 Unexport MakeClientGrab{Imp,P}ervious
xtrap used to use these, but it's gone now.  xtest still does but it's
linked statically.
2008-10-03 17:51:19 -04:00