diff options
-rw-r--r-- | Xext/xselinux_hooks.c | 4 | ||||
-rw-r--r-- | config/dbus-core.c | 4 | ||||
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | glamor/glamor.h | 3 | ||||
-rw-r--r-- | glamor/glamor_priv.h | 5 | ||||
-rw-r--r-- | glamor/glamor_text.c | 36 | ||||
-rw-r--r-- | hw/xfree86/common/xf86Module.h | 2 | ||||
-rw-r--r-- | hw/xfree86/int10/stub.c | 2 | ||||
-rw-r--r-- | hw/xfree86/int10/xf86x86emu.c | 1 | ||||
-rw-r--r-- | os/utils.c | 1 |
10 files changed, 36 insertions, 23 deletions
diff --git a/Xext/xselinux_hooks.c b/Xext/xselinux_hooks.c index 376d57518..48219a9e0 100644 --- a/Xext/xselinux_hooks.c +++ b/Xext/xselinux_hooks.c @@ -812,9 +812,9 @@ SELinuxBlockHandler(void *data, struct timeval **tv, void *read_mask) } static void -SELinuxWakeupHandler(void *data, int err, void *read_mask) +SELinuxWakeupHandler(void *data, int num_fds, void *read_mask) { - if (FD_ISSET(netlink_fd, (fd_set *) read_mask)) + if (num_fds > 0 && FD_ISSET(netlink_fd, (fd_set *) read_mask)) avc_netlink_check_nb(); } diff --git a/config/dbus-core.c b/config/dbus-core.c index b0fd92de4..8351ea4b3 100644 --- a/config/dbus-core.c +++ b/config/dbus-core.c @@ -48,11 +48,11 @@ static struct dbus_core_info bus_info; static CARD32 reconnect_timer(OsTimerPtr timer, CARD32 time, void *arg); static void -wakeup_handler(void *data, int err, void *read_mask) +wakeup_handler(void *data, int num_fds, void *read_mask) { struct dbus_core_info *info = data; - if (info->connection && FD_ISSET(info->fd, (fd_set *) read_mask)) { + if (info->connection && num_fds > 0 && FD_ISSET(info->fd, (fd_set *) read_mask)) { do { dbus_connection_read_write_dispatch(info->connection, 0); } while (info->connection && diff --git a/configure.ac b/configure.ac index 0c8b5162d..e5387bffd 100644 --- a/configure.ac +++ b/configure.ac @@ -325,6 +325,7 @@ case $host_cpu in ;; arm*) ARM_VIDEO=yes + DEFAULT_INT10="stub" ;; i*86) I386_VIDEO=yes diff --git a/glamor/glamor.h b/glamor/glamor.h index e63762b44..b0f2212d9 100644 --- a/glamor/glamor.h +++ b/glamor/glamor.h @@ -321,6 +321,9 @@ extern _X_EXPORT int glamor_create_gc(GCPtr gc); extern _X_EXPORT void glamor_validate_gc(GCPtr gc, unsigned long changes, DrawablePtr drawable); +extern Bool _X_EXPORT glamor_change_window_attributes(WindowPtr pWin, unsigned long mask); +extern void _X_EXPORT glamor_copy_window(WindowPtr window, DDXPointRec old_origin, RegionPtr src_region); + /* Glamor rendering/drawing functions with XXX_nf. * nf means no fallback within glamor internal if possible. If glamor * fail to accelerate the operation, glamor will return a false, and the diff --git a/glamor/glamor_priv.h b/glamor/glamor_priv.h index a2a21fca0..96635be39 100644 --- a/glamor/glamor_priv.h +++ b/glamor/glamor_priv.h @@ -626,10 +626,6 @@ void glamor_copy_n_to_n(DrawablePtr src, DrawablePtr dst, GCPtr gc, BoxPtr box, int nbox, int dx, int dy, Bool reverse, Bool upsidedown, Pixel bitplane, void *closure); -/* glamor_copywindow.c */ -void glamor_copy_window(WindowPtr win, DDXPointRec old_origin, - RegionPtr src_region); - /* glamor_core.c */ Bool glamor_prepare_access(DrawablePtr drawable, glamor_access_t access); void glamor_finish_access(DrawablePtr drawable); @@ -670,7 +666,6 @@ glamor_pixmap_fbo *glamor_es2_pixmap_read_prepare(PixmapPtr source, int x, Bool glamor_set_alu(ScreenPtr screen, unsigned char alu); Bool glamor_set_planemask(PixmapPtr pixmap, unsigned long planemask); -Bool glamor_change_window_attributes(WindowPtr pWin, unsigned long mask); RegionPtr glamor_bitmap_to_region(PixmapPtr pixmap); /* glamor_fill.c */ diff --git a/glamor/glamor_text.c b/glamor/glamor_text.c index 395116d5b..6e02b9aa8 100644 --- a/glamor/glamor_text.c +++ b/glamor/glamor_text.c @@ -37,6 +37,7 @@ glamor_get_glyphs(FontPtr font, glamor_font_t *glamor_font, unsigned long nglyphs; FontEncoding encoding; int char_step; + int c; if (sixteen) { char_step = 2; @@ -49,7 +50,7 @@ glamor_get_glyphs(FontPtr font, glamor_font_t *glamor_font, encoding = Linear8Bit; } - /* If the font has a default character, then we don't have to + /* If the font has a default character, then we shouldn't have to * worry about missing glyphs, so just get the whole string all at * once. Otherwise, we have to fetch chars one at a time to notice * missing ones. @@ -57,15 +58,28 @@ glamor_get_glyphs(FontPtr font, glamor_font_t *glamor_font, if (glamor_font->default_char) { GetGlyphs(font, (unsigned long) count, (unsigned char *) chars, encoding, &nglyphs, charinfo); - } else { - int c; - for (c = 0; c < count; c++) { - GetGlyphs(font, 1, (unsigned char *) chars, - encoding, &nglyphs, &charinfo[c]); - if (!nglyphs) - charinfo[c] = NULL; - chars += char_step; - } + + /* Make sure it worked. There's a bug in libXfont through + * version 1.4.7 which would cause it to fail when the font is + * a 2D font without a first row, and the application sends a + * 1-d request. In this case, libXfont would return zero + * glyphs, even when the font had a default character. + * + * It's easy enough for us to work around that bug here by + * simply checking the returned nglyphs and falling through to + * the one-at-a-time code below. Not doing this check would + * result in uninitialized memory accesses in the rendering code. + */ + if (nglyphs == count) + return; + } + + for (c = 0; c < count; c++) { + GetGlyphs(font, 1, (unsigned char *) chars, + encoding, &nglyphs, &charinfo[c]); + if (!nglyphs) + charinfo[c] = NULL; + chars += char_step; } } @@ -508,7 +522,7 @@ Bool glamor_image_text16_nf(DrawablePtr drawable, GCPtr gc, int x, int y, int count, unsigned short *chars) { - return glamor_image_text(drawable, gc, x, y, count, (char *) chars, FALSE); + return glamor_image_text(drawable, gc, x, y, count, (char *) chars, TRUE); } void diff --git a/hw/xfree86/common/xf86Module.h b/hw/xfree86/common/xf86Module.h index 62ac95d5a..b848f53f1 100644 --- a/hw/xfree86/common/xf86Module.h +++ b/hw/xfree86/common/xf86Module.h @@ -80,7 +80,7 @@ typedef enum { * mask is 0xFFFF0000. */ #define ABI_ANSIC_VERSION SET_ABI_VERSION(0, 4) -#define ABI_VIDEODRV_VERSION SET_ABI_VERSION(17, 0) +#define ABI_VIDEODRV_VERSION SET_ABI_VERSION(18, 0) #define ABI_XINPUT_VERSION SET_ABI_VERSION(21, 0) #define ABI_EXTENSION_VERSION SET_ABI_VERSION(8, 0) #define ABI_FONT_VERSION SET_ABI_VERSION(0, 6) diff --git a/hw/xfree86/int10/stub.c b/hw/xfree86/int10/stub.c index 40e0ba719..4bbcddeda 100644 --- a/hw/xfree86/int10/stub.c +++ b/hw/xfree86/int10/stub.c @@ -63,7 +63,7 @@ xf86ExecX86int10(xf86Int10InfoPtr pInt) } void * -xf86int10Addr(xf86Int10InfoPtr pInt, CARD32 addr) +xf86int10Addr(xf86Int10InfoPtr pInt, uint32_t addr) { return 0; } diff --git a/hw/xfree86/int10/xf86x86emu.c b/hw/xfree86/int10/xf86x86emu.c index b9a4d3603..4b0a13090 100644 --- a/hw/xfree86/int10/xf86x86emu.c +++ b/hw/xfree86/int10/xf86x86emu.c @@ -9,7 +9,6 @@ #include <x86emu.h> #include "xf86.h" -#include "compiler.h" #include "xf86_OSproc.h" #include "xf86Pci.h" #define _INT10_PRIVATE diff --git a/os/utils.c b/os/utils.c index bc5e7df4d..ed7581e1c 100644 --- a/os/utils.c +++ b/os/utils.c @@ -529,6 +529,7 @@ UseMsg(void) ErrorF("-cc int default color visual class\n"); ErrorF("-nocursor disable the cursor\n"); ErrorF("-core generate core dump on fatal error\n"); + ErrorF("-displayfd fd file descriptor to write display number to when ready to connect\n"); ErrorF("-dpi int screen resolution in dots per inch\n"); #ifdef DPMSExtension ErrorF("-dpms disables VESA DPMS monitor control\n"); |