Update to libXv 1.0.9

This commit is contained in:
matthieu 2013-06-23 09:51:37 +00:00
parent f099f537b7
commit 459e6d66cd
4 changed files with 57 additions and 13 deletions

View File

@ -1,3 +1,32 @@
commit d58f74ebfd0c56ffeb8e288c65592228af197a2e
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date: Sat Jun 22 19:06:09 2013 -0700
libXv 1.0.9
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
commit 22cc0c897a28a41d49fe68277bb3c002f54bbb48
Author: Daphne Pfister <daphnediane@mac.com>
Date: Sat Jun 1 22:27:23 2013 -0400
Bug 65252: Ensure final name is nil-terminated & none point to uninitialized memory.
This patch attempts to fix this bug by ensuring that there is at least one
nil byte at the end of all the name strings. This should prevent reading
past the end of the allocation as well as exposing uninitialized memory.
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
commit edfb6fc397686c1892603d0f86a9aadf14dbc12e
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date: Sat Jun 1 17:26:11 2013 -0700
XvQueryPortAttributes: add a comment explaining memory strategy
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
commit 179ed259e75a62e74532e36f52f3838deb2aac92
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
Date: Fri May 31 17:49:24 2013 -0700

20
lib/libXv/configure vendored
View File

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for libXv 1.0.8.
# Generated by GNU Autoconf 2.69 for libXv 1.0.9.
#
# Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>.
#
@ -591,8 +591,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='libXv'
PACKAGE_TARNAME='libXv'
PACKAGE_VERSION='1.0.8'
PACKAGE_STRING='libXv 1.0.8'
PACKAGE_VERSION='1.0.9'
PACKAGE_STRING='libXv 1.0.9'
PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg'
PACKAGE_URL=''
@ -1357,7 +1357,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures libXv 1.0.8 to adapt to many kinds of systems.
\`configure' configures libXv 1.0.9 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1427,7 +1427,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of libXv 1.0.8:";;
short | recursive ) echo "Configuration of libXv 1.0.9:";;
esac
cat <<\_ACEOF
@ -1552,7 +1552,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
libXv configure 1.0.8
libXv configure 1.0.9
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@ -1876,7 +1876,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by libXv $as_me 1.0.8, which was
It was created by libXv $as_me 1.0.9, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@ -2705,7 +2705,7 @@ fi
# Define the identity of the package.
PACKAGE='libXv'
VERSION='1.0.8'
VERSION='1.0.9'
cat >>confdefs.h <<_ACEOF
@ -18308,7 +18308,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by libXv $as_me 1.0.8, which was
This file was extended by libXv $as_me 1.0.9, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@ -18374,7 +18374,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
libXv config.status 1.0.8
libXv config.status 1.0.9
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"

View File

@ -22,7 +22,7 @@
# Initialize Autoconf
AC_PREREQ([2.60])
AC_INIT([libXv], [1.0.8],
AC_INIT([libXv], [1.0.9],
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXv])
AC_CONFIG_SRCDIR([Makefile.am])
AC_CONFIG_HEADERS([config.h])

View File

@ -850,12 +850,23 @@ XvQueryPortAttributes(Display *dpy, XvPortID port, int *num)
return ret;
}
/*
* X server sends data packed as:
* attribute1, name1, attribute2, name2, ...
* We allocate a single buffer large enough to hold them all and
* then de-interleave the data so we return it to clients as:
* attribute1, attribute2, ..., name1, name2, ...
* so that clients may refer to attributes as a simple array of
* structs: attributes[0], attributes[1], ...
* and free it as a single/simple buffer.
*/
if(rep.num_attributes) {
unsigned long size;
/* limit each part to no more than one half the max size */
if ((rep.num_attributes < ((INT_MAX / 2) / sizeof(XvAttribute))) &&
(rep.text_size < (INT_MAX / 2))) {
size = (rep.num_attributes * sizeof(XvAttribute)) + rep.text_size;
(rep.text_size < (INT_MAX / 2)-1)) {
size = (rep.num_attributes * sizeof(XvAttribute)) + rep.text_size + 1;
ret = Xmalloc(size);
}
@ -880,6 +891,10 @@ XvQueryPortAttributes(Display *dpy, XvPortID port, int *num)
}
(*num)++;
}
/* ensure final string is nil-terminated to avoid exposure of
uninitialized memory */
*marker = '\0';
} else
_XEatDataWords(dpy, rep.length);
}