Compare commits
41 Commits
Author | SHA1 | Date |
---|---|---|
|
c488e08456 | |
|
1a20a3e14b | |
|
c2b1db7067 | |
|
a97307be01 | |
|
d57753c02c | |
|
3675bc4f5a | |
|
c84063a22d | |
|
d69903646d | |
|
04ae9da23b | |
|
26835b2d19 | |
|
b5bf5ad14d | |
|
7b2dc6e532 | |
|
c8bc3519ac | |
|
c5e74df90d | |
|
c0a03f9a24 | |
|
bf821bf62c | |
|
ec11cb1031 | |
|
520181c4ff | |
|
6aec805cce | |
|
2b737fbd9f | |
|
b4dd757e2a | |
|
0a814aab28 | |
|
421a7010ea | |
|
fe7c362aab | |
|
7a9a94424f | |
|
88bcfd0a90 | |
|
d8427aecb2 | |
|
a14a744ce4 | |
|
991b877472 | |
|
c3defef042 | |
|
f47f9459f4 | |
|
8369052ada | |
|
696b9b5698 | |
|
68e79c4091 | |
|
4101233f14 | |
|
9a5bc66ccf | |
|
a045a0a262 | |
|
6e2acfbfa9 | |
|
3d411228a7 | |
|
b722a23936 | |
|
878ccfceae |
|
@ -1,11 +1,11 @@
|
|||
hi128-app-qt4-logo.png
|
||||
hi48-app-qt4-logo.png
|
||||
gstreamer-logo.svg
|
||||
qt-x11-opensource-src-4.5.2.tar.bz2
|
||||
qt-copy-patches-20090626svn.tar.bz2
|
||||
hi128-phonon-gstreamer.png
|
||||
hi16-phonon-gstreamer.png
|
||||
hi22-phonon-gstreamer.png
|
||||
hi32-phonon-gstreamer.png
|
||||
hi48-phonon-gstreamer.png
|
||||
hi64-phonon-gstreamer.png
|
||||
qt-everywhere-opensource-src-4.6.2.tar.gz
|
||||
qt-everywhere-opensource-src-4.6.3.tar.gz
|
|
@ -0,0 +1,117 @@
|
|||
From b48e2091871516496cf0b133249fbf5326a55831 Mon Sep 17 00:00:00 2001
|
||||
From: Lubos Lunak <l.lunak@kde.org>
|
||||
Date: Sat, 23 Feb 2008 16:44:52 +0100
|
||||
Subject: [PATCH 01/13] This patch uses object name as a fallback for window role if no window
|
||||
role is set explicitly using setWindowRole(). Since Qt3 always used
|
||||
the object name as the window role and most Qt3/KDE3 code is ported to
|
||||
call setObjectName(),
|
||||
|
||||
this makes the window role set in many cases (which KWin uses for window identifying).
|
||||
|
||||
NOTE: It is suggested to apply patch #0209 as well when this patch is used.
|
||||
|
||||
qt-bugs@ issue : 167704
|
||||
Trolltech task ID : 168283 (status: "fixed" for Qt 4.4.0, but effectively refused)
|
||||
---
|
||||
src/corelib/kernel/qobject.cpp | 8 ++++++++
|
||||
src/corelib/kernel/qobject_p.h | 3 +++
|
||||
src/gui/kernel/qwidget_p.h | 1 +
|
||||
src/gui/kernel/qwidget_x11.cpp | 27 +++++++++++++++++++++------
|
||||
4 files changed, 33 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp
|
||||
index 6487194..ef0369e 100644
|
||||
--- a/src/corelib/kernel/qobject.cpp
|
||||
+++ b/src/corelib/kernel/qobject.cpp
|
||||
@@ -993,8 +993,16 @@ void QObject::setObjectName(const QString &name)
|
||||
{
|
||||
Q_D(QObject);
|
||||
d->objectName = name;
|
||||
+#if defined(Q_WS_X11)
|
||||
+ d->checkWindowRole();
|
||||
+#endif
|
||||
}
|
||||
|
||||
+#if defined(Q_WS_X11)
|
||||
+void QObjectPrivate::checkWindowRole()
|
||||
+{
|
||||
+}
|
||||
+#endif
|
||||
|
||||
#ifdef QT3_SUPPORT
|
||||
/*! \internal
|
||||
diff --git a/src/corelib/kernel/qobject_p.h b/src/corelib/kernel/qobject_p.h
|
||||
index 0bcccba..6ab9e10 100644
|
||||
--- a/src/corelib/kernel/qobject_p.h
|
||||
+++ b/src/corelib/kernel/qobject_p.h
|
||||
@@ -144,6 +144,9 @@ public:
|
||||
mutable quint32 connectedSignals;
|
||||
|
||||
QString objectName;
|
||||
+#if defined(Q_WS_X11)
|
||||
+ virtual void checkWindowRole();
|
||||
+#endif
|
||||
|
||||
// Note: you must hold the signalSlotLock() before accessing the lists below or calling the functions
|
||||
struct Connection
|
||||
diff --git a/src/gui/kernel/qwidget_p.h b/src/gui/kernel/qwidget_p.h
|
||||
index 774e390..176d6fa 100644
|
||||
--- a/src/gui/kernel/qwidget_p.h
|
||||
+++ b/src/gui/kernel/qwidget_p.h
|
||||
@@ -358,6 +358,7 @@ public:
|
||||
|
||||
#if defined(Q_WS_X11)
|
||||
void setWindowRole();
|
||||
+ virtual void checkWindowRole();
|
||||
void sendStartupMessage(const char *message) const;
|
||||
void setNetWmWindowTypes();
|
||||
void x11UpdateIsOpaque();
|
||||
diff --git a/src/gui/kernel/qwidget_x11.cpp b/src/gui/kernel/qwidget_x11.cpp
|
||||
index 79ee8c9..b56849c 100644
|
||||
--- a/src/gui/kernel/qwidget_x11.cpp
|
||||
+++ b/src/gui/kernel/qwidget_x11.cpp
|
||||
@@ -778,13 +778,17 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
||||
data.fstrut_dirty = 1;
|
||||
|
||||
// declare the widget's window role
|
||||
+ QByteArray windowRole;
|
||||
if (QTLWExtra *topData = maybeTopData()) {
|
||||
- if (!topData->role.isEmpty()) {
|
||||
- QByteArray windowRole = topData->role.toUtf8();
|
||||
- XChangeProperty(dpy, id,
|
||||
- ATOM(WM_WINDOW_ROLE), XA_STRING, 8, PropModeReplace,
|
||||
- (unsigned char *)windowRole.constData(), windowRole.length());
|
||||
- }
|
||||
+ if (!topData->role.isEmpty())
|
||||
+ windowRole = topData->role.toUtf8();
|
||||
+ }
|
||||
+ if (windowRole.isEmpty()) // use object name as a fallback
|
||||
+ windowRole = objectName.toUtf8();
|
||||
+ if (!windowRole.isEmpty()) {
|
||||
+ XChangeProperty(dpy, id,
|
||||
+ ATOM(WM_WINDOW_ROLE), XA_STRING, 8, PropModeReplace,
|
||||
+ (unsigned char *)windowRole.constData(), windowRole.length());
|
||||
}
|
||||
|
||||
// set client leader property
|
||||
@@ -2768,6 +2772,17 @@ void QWidgetPrivate::setWindowRole()
|
||||
(unsigned char *)windowRole.constData(), windowRole.length());
|
||||
}
|
||||
|
||||
+void QWidgetPrivate::checkWindowRole()
|
||||
+{
|
||||
+ Q_Q(QWidget);
|
||||
+ if( !q->windowRole().isEmpty() || !q->internalWinId())
|
||||
+ return;
|
||||
+ QByteArray windowRole = objectName.toUtf8(); // use as a fallback
|
||||
+ XChangeProperty(X11->display, q->internalWinId(),
|
||||
+ ATOM(WM_WINDOW_ROLE), XA_STRING, 8, PropModeReplace,
|
||||
+ (unsigned char *)windowRole.constData(), windowRole.length());
|
||||
+}
|
||||
+
|
||||
Q_GLOBAL_STATIC(QX11PaintEngine, qt_widget_paintengine)
|
||||
QPaintEngine *QWidget::paintEngine() const
|
||||
{
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,67 @@
|
|||
From 339e220e29ff39b86705438b4be6f90e5618d27b Mon Sep 17 00:00:00 2001
|
||||
From: Lubos Lunak <l.lunak@kde.org>
|
||||
Date: Tue, 2 Oct 2007 16:08:32 +0200
|
||||
Subject: [PATCH 02/13] This patch makes override-redirect windows (popup menu, dropdown menu,
|
||||
tooltip, combobox, etc.) also have more window properties like WM_CLASS,
|
||||
so they can be used when compositing.
|
||||
|
||||
qt-bugs@ issue : none
|
||||
bugs.kde.org number : none
|
||||
---
|
||||
src/gui/kernel/qwidget_x11.cpp | 21 +++++++++++++++------
|
||||
1 files changed, 15 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qwidget_x11.cpp b/src/gui/kernel/qwidget_x11.cpp
|
||||
index 79ee8c9..a74a849 100644
|
||||
--- a/src/gui/kernel/qwidget_x11.cpp
|
||||
+++ b/src/gui/kernel/qwidget_x11.cpp
|
||||
@@ -719,6 +719,11 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
||||
Q_ASSERT(id);
|
||||
XChangeWindowAttributes(dpy, id, CWOverrideRedirect | CWSaveUnder,
|
||||
&wsa);
|
||||
+ XClassHint class_hint;
|
||||
+ QByteArray appName = qAppName().toLatin1();
|
||||
+ class_hint.res_name = appName.data(); // application name
|
||||
+ class_hint.res_class = const_cast<char *>(QX11Info::appClass()); // application class
|
||||
+ XSetWMProperties(dpy, id, 0, 0, 0, 0, 0, 0, &class_hint);
|
||||
} else if (topLevel && !desktop) { // top-level widget
|
||||
if (!X11->wm_client_leader)
|
||||
create_wm_client_leader();
|
||||
@@ -769,13 +774,21 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
||||
// set EWMH window types
|
||||
setNetWmWindowTypes();
|
||||
|
||||
+ // when we create a toplevel widget, the frame strut should be dirty
|
||||
+ data.fstrut_dirty = 1;
|
||||
+
|
||||
+ } else {
|
||||
+ // non-toplevel widgets don't have a frame, so no need to
|
||||
+ // update the strut
|
||||
+ data.fstrut_dirty = 0;
|
||||
+ }
|
||||
+
|
||||
+ if (initializeWindow && (popup || (topLevel && !desktop))) { // properties set on all toplevel windows
|
||||
// set _NET_WM_PID
|
||||
long curr_pid = getpid();
|
||||
XChangeProperty(dpy, id, ATOM(_NET_WM_PID), XA_CARDINAL, 32, PropModeReplace,
|
||||
(unsigned char *) &curr_pid, 1);
|
||||
|
||||
- // when we create a toplevel widget, the frame strut should be dirty
|
||||
- data.fstrut_dirty = 1;
|
||||
|
||||
// declare the widget's window role
|
||||
if (QTLWExtra *topData = maybeTopData()) {
|
||||
@@ -791,10 +804,6 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
||||
XChangeProperty(dpy, id, ATOM(WM_CLIENT_LEADER),
|
||||
XA_WINDOW, 32, PropModeReplace,
|
||||
(unsigned char *)&X11->wm_client_leader, 1);
|
||||
- } else {
|
||||
- // non-toplevel widgets don't have a frame, so no need to
|
||||
- // update the strut
|
||||
- data.fstrut_dirty = 0;
|
||||
}
|
||||
|
||||
if (initializeWindow && q->internalWinId()) {
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
From 68eaa07de69e873b89d4aba341c6ed1ca81f6819 Mon Sep 17 00:00:00 2001
|
||||
From: Lubos Lunak <l.lunak@kde.org>
|
||||
Date: Wed, 30 Jan 2008 14:24:01 +0100
|
||||
Subject: [PATCH 03/13] This patch changes QObjectPrivateVersion, thus preventing mixing
|
||||
parts of upstream Qt and qt-copy. In general it is a bad idea to mix
|
||||
e.g. libQtCore from one build and libQtGui from another one, and other
|
||||
qt-copy patches could make changes in Qt internal structures that could
|
||||
cause problems when mixed with upstream Qt.
|
||||
|
||||
This patch does not make qt-copy binary incompatible with upstream Qt.
|
||||
It only further enforces using the same sources for the whole Qt build.
|
||||
|
||||
qt-bugs@ issue : none
|
||||
Trolltech task ID : none
|
||||
bugs.kde.org number : none
|
||||
---
|
||||
src/corelib/kernel/qobject_p.h | 4 +++-
|
||||
1 files changed, 3 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/src/corelib/kernel/qobject_p.h b/src/corelib/kernel/qobject_p.h
|
||||
index 0bcccba..88192fd 100644
|
||||
--- a/src/corelib/kernel/qobject_p.h
|
||||
+++ b/src/corelib/kernel/qobject_p.h
|
||||
@@ -83,7 +83,9 @@ extern QSignalSpyCallbackSet Q_CORE_EXPORT qt_signal_spy_callback_set;
|
||||
|
||||
inline QObjectData::~QObjectData() {}
|
||||
|
||||
-enum { QObjectPrivateVersion = QT_VERSION };
|
||||
+// add 0x1000000 to mark it as qt-copy version, with possible modifications
|
||||
+// in some Q*Private class
|
||||
+enum { QObjectPrivateVersion = QT_VERSION + 0x1000000 };
|
||||
|
||||
class Q_CORE_EXPORT QObjectPrivate : public QObjectData
|
||||
{
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
From 86fc0d43cdcf3232ae0e4e6f4f28cf8f1a45ede5 Mon Sep 17 00:00:00 2001
|
||||
From: Benjamin Reed <rangerrick@befunk.com>
|
||||
Date: Tue, 19 Feb 2008 17:37:37 +0100
|
||||
Subject: [PATCH 04/13] This patch adds support for using -isystem to allow putting an include
|
||||
directory at the end of the compiler's header search path.
|
||||
|
||||
I don't have the exact output anymore (I've since patched Qt's configure) but
|
||||
essentially, since I have pcre.h in /opt/kde4-deps/include, it was
|
||||
conflicting with Qt's (modified) pcre.h in the WebKit bits, since
|
||||
-I /opt/kde4-deps/include ends up in CXXFLAGS in the generated makefiles, it
|
||||
comes *before* the specific locations in INCPATH on the compile line, and you
|
||||
end up with a conflict with the system-installed pcre.h.
|
||||
|
||||
Presumably, if your pcre.h is in /usr/include as on most Linux systems, you
|
||||
wouldn't notice this issue since /usr/include's already in your include path
|
||||
and people likely don't pass -I /usr/include to configure. I suspect that on
|
||||
any platform with a regular, system-installed pcre.h (or clucene headers),
|
||||
adding -I /usr/include would exhibit this bug, just as a custom-installed
|
||||
pcre/clucene in another root would.
|
||||
|
||||
qt-bugs@ issue : 199610
|
||||
Trolltech task ID :
|
||||
bugs.kde.org number :
|
||||
---
|
||||
configure | 8 ++++++++
|
||||
1 files changed, 8 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index 2c108ad..610a201 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -927,6 +927,11 @@ while [ "$#" -gt 0 ]; do
|
||||
VAL=`echo $1 | sed 's,-D,,'`
|
||||
fi
|
||||
;;
|
||||
+ -isystem)
|
||||
+ VAR="add_isystempath"
|
||||
+ shift
|
||||
+ VAL="$1"
|
||||
+ ;;
|
||||
-I?*|-I)
|
||||
VAR="add_ipath"
|
||||
if [ "$1" = "-I" ]; then
|
||||
@@ -1890,6 +1895,9 @@ while [ "$#" -gt 0 ]; do
|
||||
add_ipath)
|
||||
I_FLAGS="$I_FLAGS -I\"${VAL}\""
|
||||
;;
|
||||
+ add_isystempath)
|
||||
+ I_FLAGS="$I_FLAGS -isystem \"${VAL}\""
|
||||
+ ;;
|
||||
add_lpath)
|
||||
L_FLAGS="$L_FLAGS -L\"${VAL}\""
|
||||
;;
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,47 @@
|
|||
From 733d1afd03908d695aa8a6518f453b9ff0e5b8a2 Mon Sep 17 00:00:00 2001
|
||||
From: Robert Knight <robertknight@gmail.com>
|
||||
Date: Sun, 20 Apr 2008 16:28:31 +0200
|
||||
Subject: [PATCH 05/13] When tabs are inserted or removed in a QTabBar,
|
||||
QTabBarPrivate::refresh() is called to update the layout. If the
|
||||
tabbar widget is hidden, this just sets a boolean variable
|
||||
(layoutDirty) and returns, so the parent widget's layout is not
|
||||
notified about the possible geometry change.
|
||||
|
||||
Prior to Qt 4.4 this was not a problem because the geometry was
|
||||
recalculated in QTabBar::sizeHint() if the layoutDirty variable was
|
||||
set. In Qt 4.4 however the layout caches size hint information in
|
||||
QWidgetItemV2. Since the cache information is not invalidated, the
|
||||
layout may end up using out-of-date size hint information to compute
|
||||
the widget size.
|
||||
|
||||
If the QTabBar is empty when QTabBar::sizeHint() is called, it will
|
||||
return a size with a height of 0, which will be kept in the cache and
|
||||
so the tab bar will never be shown.
|
||||
|
||||
This patch fixes the problem by calling updateGeometry() whenever the
|
||||
tab bar's layout is refreshed.
|
||||
|
||||
qt-bugs@ issue : 208185
|
||||
Trolltech task ID : 208349
|
||||
bugs.kde.org number : 159014
|
||||
---
|
||||
src/gui/widgets/qtabbar.cpp | 2 +-
|
||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/src/gui/widgets/qtabbar.cpp b/src/gui/widgets/qtabbar.cpp
|
||||
index 419d456..41107a0 100644
|
||||
--- a/src/gui/widgets/qtabbar.cpp
|
||||
+++ b/src/gui/widgets/qtabbar.cpp
|
||||
@@ -678,8 +678,8 @@ void QTabBarPrivate::refresh()
|
||||
layoutTabs();
|
||||
makeVisible(currentIndex);
|
||||
q->update();
|
||||
- q->updateGeometry();
|
||||
}
|
||||
+ q->updateGeometry();
|
||||
}
|
||||
|
||||
/*!
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,67 @@
|
|||
From 8e28e0603a900e1b18ebfd14c4f87b16dabf4cf6 Mon Sep 17 00:00:00 2001
|
||||
From: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
||||
Date: Fri, 19 Sep 2008 17:41:26 +0200
|
||||
Subject: [PATCH 06/13] Fix configure.exe to do an out-of-source build on windows
|
||||
|
||||
qt-bugs@ issue : N227213
|
||||
Trolltech task ID : none yet
|
||||
---
|
||||
bin/syncqt | 6 +++++-
|
||||
projects.pro | 3 +++
|
||||
src/tools/moc/main.cpp | 6 ++++++
|
||||
3 files changed, 14 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/bin/syncqt b/bin/syncqt
|
||||
index 7a9f1d3..b5a8e1c 100755
|
||||
--- a/bin/syncqt
|
||||
+++ b/bin/syncqt
|
||||
@@ -365,9 +365,13 @@ sub fixPaths {
|
||||
$match_dir = $tmp;
|
||||
$i = $slash;
|
||||
}
|
||||
+ my $cnt_ofs = 0;
|
||||
+ if($match_dir =~ /^[a-zA-Z]:$/) {
|
||||
+ $cnt_ofs = 1;
|
||||
+ }
|
||||
if($match_dir) {
|
||||
my $after = substr($dir, length($match_dir));
|
||||
- my $count = ($after =~ tr,/,,);
|
||||
+ my $count = ($after =~ tr,/,,) - $cnt_ofs;
|
||||
my $dots = "";
|
||||
for(my $i = 0; $i < $count; $i++) {
|
||||
$dots .= "../";
|
||||
diff --git a/projects.pro b/projects.pro
|
||||
index 2596c0a..3ba0688 100644
|
||||
--- a/projects.pro
|
||||
+++ b/projects.pro
|
||||
@@ -127,6 +127,9 @@ unix {
|
||||
DEFAULT_QMAKESPEC ~= s,^.*mkspecs/,,g
|
||||
mkspecs.commands += $(DEL_FILE) $(INSTALL_ROOT)$$mkspecs.path/default; $(SYMLINK) $$DEFAULT_QMAKESPEC $(INSTALL_ROOT)$$mkspecs.path/default
|
||||
}
|
||||
+win32 {
|
||||
+ mkspecs.files += $$QT_BUILD_TREE/mkspecs/default
|
||||
+}
|
||||
INSTALLS += mkspecs
|
||||
|
||||
false:macx { #mac install location
|
||||
diff --git a/src/tools/moc/main.cpp b/src/tools/moc/main.cpp
|
||||
index d519b09..7979836 100644
|
||||
--- a/src/tools/moc/main.cpp
|
||||
+++ b/src/tools/moc/main.cpp
|
||||
@@ -94,7 +94,13 @@ static QByteArray combinePath(const char *infile, const char *outfile)
|
||||
inSplitted.prepend(QLatin1String(".."));
|
||||
}
|
||||
inSplitted.append(inFileInfo.fileName());
|
||||
+#ifdef Q_WS_WIN
|
||||
+ const QString rel = inSplitted.join(QLatin1String("/"));
|
||||
+ const QString abs = inFileInfo.absoluteFilePath();
|
||||
+ return QFile::encodeName(rel.length() < abs.length() ? rel : abs);
|
||||
+#else
|
||||
return QFile::encodeName(inSplitted.join(QLatin1String("/")));
|
||||
+#endif
|
||||
}
|
||||
|
||||
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
From 0afcf33127c6ccbe5dfaae4f4c5e02f28dc10ae1 Mon Sep 17 00:00:00 2001
|
||||
From: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
||||
Date: Thu, 8 May 2008 21:25:49 +0200
|
||||
Subject: [PATCH 07/13] When using qmake outside qt src tree, it sometimes generates wrong
|
||||
paths (wrong path separator)
|
||||
|
||||
qt-bugs@ issue : none
|
||||
Trolltech task ID : 214661
|
||||
---
|
||||
qmake/property.cpp | 29 ++++++++++++++++-------------
|
||||
1 files changed, 16 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/qmake/property.cpp b/qmake/property.cpp
|
||||
index 8ba89f9..dd78349 100644
|
||||
--- a/qmake/property.cpp
|
||||
+++ b/qmake/property.cpp
|
||||
@@ -81,29 +81,32 @@ QMakeProperty::keyBase(bool version) const
|
||||
QString
|
||||
QMakeProperty::value(QString v, bool just_check)
|
||||
{
|
||||
+ QString ret;
|
||||
if(v == "QT_INSTALL_PREFIX")
|
||||
- return QLibraryInfo::location(QLibraryInfo::PrefixPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::PrefixPath);
|
||||
else if(v == "QT_INSTALL_DATA")
|
||||
- return QLibraryInfo::location(QLibraryInfo::DataPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::DataPath);
|
||||
else if(v == "QT_INSTALL_DOCS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::DocumentationPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::DocumentationPath);
|
||||
else if(v == "QT_INSTALL_HEADERS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::HeadersPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::HeadersPath);
|
||||
else if(v == "QT_INSTALL_LIBS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::LibrariesPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::LibrariesPath);
|
||||
else if(v == "QT_INSTALL_BINS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::BinariesPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::BinariesPath);
|
||||
else if(v == "QT_INSTALL_PLUGINS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::PluginsPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::PluginsPath);
|
||||
else if(v == "QT_INSTALL_TRANSLATIONS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::TranslationsPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::TranslationsPath);
|
||||
else if(v == "QT_INSTALL_CONFIGURATION")
|
||||
- return QLibraryInfo::location(QLibraryInfo::SettingsPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::SettingsPath);
|
||||
else if(v == "QT_INSTALL_EXAMPLES")
|
||||
- return QLibraryInfo::location(QLibraryInfo::ExamplesPath);
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::ExamplesPath);
|
||||
else if(v == "QT_INSTALL_DEMOS")
|
||||
- return QLibraryInfo::location(QLibraryInfo::DemosPath);
|
||||
- else if(v == "QMAKE_MKSPECS")
|
||||
+ ret = QLibraryInfo::location(QLibraryInfo::DemosPath);
|
||||
+ if(!ret.isEmpty())
|
||||
+ return QDir::toNativeSeparators(ret);
|
||||
+ if(v == "QMAKE_MKSPECS")
|
||||
return qmake_mkspec_paths().join(Option::target_mode == Option::TARG_WIN_MODE ? ";" : ":");
|
||||
else if(v == "QMAKE_VERSION")
|
||||
return qmake_version();
|
||||
@@ -116,7 +119,7 @@ QMakeProperty::value(QString v, bool just_check)
|
||||
int slash = v.lastIndexOf('/');
|
||||
QVariant var = settings->value(keyBase(slash == -1) + v);
|
||||
bool ok = var.isValid();
|
||||
- QString ret = var.toString();
|
||||
+ ret = var.toString();
|
||||
if(!ok) {
|
||||
QString version = qmake_version();
|
||||
if(slash != -1) {
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,93 @@
|
|||
From 8731ab999b849dac4716e3d29f5f55ed8e56438e Mon Sep 17 00:00:00 2001
|
||||
From: Thiago Macieira <thiago.macieira@nokia.com>
|
||||
Date: Thu, 25 Jun 2009 13:50:29 +0200
|
||||
Subject: [PATCH 08/13] This patch makes the raster graphics system use shared images instead
|
||||
of shared pixmaps.
|
||||
|
||||
Shared memory pixmaps are deprecated since they are slower than shared
|
||||
images with modern graphics hardware. They are also not supported by EXA
|
||||
drivers and can be disabled in the latest version of the NVidia driver.
|
||||
|
||||
qt-bugs@ issue : none
|
||||
Qt Software task ID : none
|
||||
bugs.kde.org number : none
|
||||
---
|
||||
src/gui/image/qnativeimage.cpp | 10 ----------
|
||||
src/gui/image/qnativeimage_p.h | 1 -
|
||||
src/gui/painting/qwindowsurface_raster.cpp | 13 ++++++++++---
|
||||
3 files changed, 10 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/src/gui/image/qnativeimage.cpp b/src/gui/image/qnativeimage.cpp
|
||||
index 3745708..3c21fce 100644
|
||||
--- a/src/gui/image/qnativeimage.cpp
|
||||
+++ b/src/gui/image/qnativeimage.cpp
|
||||
@@ -147,7 +147,6 @@ QNativeImage::QNativeImage(int width, int height, QImage::Format format,bool /*
|
||||
{
|
||||
if (!X11->use_mitshm) {
|
||||
xshmimg = 0;
|
||||
- xshmpm = 0;
|
||||
image = QImage(width, height, format);
|
||||
return;
|
||||
}
|
||||
@@ -191,11 +190,6 @@ QNativeImage::QNativeImage(int width, int height, QImage::Format format,bool /*
|
||||
shmctl(xshminfo.shmid, IPC_RMID, 0);
|
||||
return;
|
||||
}
|
||||
- xshmpm = XShmCreatePixmap(X11->display, DefaultRootWindow(X11->display), xshmimg->data,
|
||||
- &xshminfo, width, height, dd);
|
||||
- if (!xshmpm) {
|
||||
- qWarning() << "QNativeImage: Unable to create shared Pixmap.";
|
||||
- }
|
||||
}
|
||||
|
||||
|
||||
@@ -204,10 +198,6 @@ QNativeImage::~QNativeImage()
|
||||
if (!xshmimg)
|
||||
return;
|
||||
|
||||
- if (xshmpm) {
|
||||
- XFreePixmap(X11->display, xshmpm);
|
||||
- xshmpm = 0;
|
||||
- }
|
||||
XShmDetach(X11->display, &xshminfo);
|
||||
xshmimg->data = 0;
|
||||
XDestroyImage(xshmimg);
|
||||
diff --git a/src/gui/image/qnativeimage_p.h b/src/gui/image/qnativeimage_p.h
|
||||
index 07d5dfe..ba01854 100644
|
||||
--- a/src/gui/image/qnativeimage_p.h
|
||||
+++ b/src/gui/image/qnativeimage_p.h
|
||||
@@ -90,7 +90,6 @@ public:
|
||||
|
||||
#elif defined(Q_WS_X11) && !defined(QT_NO_MITSHM)
|
||||
XImage *xshmimg;
|
||||
- Pixmap xshmpm;
|
||||
XShmSegmentInfo xshminfo;
|
||||
|
||||
#elif defined(Q_WS_MAC)
|
||||
diff --git a/src/gui/painting/qwindowsurface_raster.cpp b/src/gui/painting/qwindowsurface_raster.cpp
|
||||
index d6fb03b..09963d9 100644
|
||||
--- a/src/gui/painting/qwindowsurface_raster.cpp
|
||||
+++ b/src/gui/painting/qwindowsurface_raster.cpp
|
||||
@@ -220,9 +220,16 @@ void QRasterWindowSurface::flush(QWidget *widget, const QRegion &rgn, const QPoi
|
||||
|
||||
QRect br = rgn.boundingRect().translated(offset);
|
||||
#ifndef QT_NO_MITSHM
|
||||
- if (d_ptr->image->xshmpm) {
|
||||
- XCopyArea(X11->display, d_ptr->image->xshmpm, widget->handle(), d_ptr->gc,
|
||||
- br.x(), br.y(), br.width(), br.height(), wbr.x(), wbr.y());
|
||||
+ if (d_ptr->image->xshmimg && (br.width() * br.height() > 65536)) {
|
||||
+ const QImage &src = d->image->image;
|
||||
+ br = br.intersected(src.rect());
|
||||
+ // Hack to make sure we satisify the PutImage() constraints in the X server,
|
||||
+ // since the doShmPutImage() route currently forces a migration to system ram.
|
||||
+ wbr.setX(wbr.x() - br.x());
|
||||
+ br.setX(0);
|
||||
+ br.setWidth(src.width());
|
||||
+ XShmPutImage(X11->display, widget->handle(), d_ptr->gc, d_ptr->image->xshmimg,
|
||||
+ br.x(), br.y(), wbr.x(), wbr.y(), br.width(), br.height(), False);
|
||||
XSync(X11->display, False);
|
||||
} else
|
||||
#endif
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
From bb8255da422470c5012b6b1c4c24eb2afb6804dc Mon Sep 17 00:00:00 2001
|
||||
From: Thiago Macieira <thiago.macieira@nokia.com>
|
||||
Date: Fri, 26 Jun 2009 11:41:45 +0200
|
||||
Subject: [PATCH 09/13] Restore a section of the file that got removed due to conflict resolution.
|
||||
|
||||
Thanks to Kevin Kofler for pointing this out
|
||||
---
|
||||
src/gui/kernel/qapplication_x11.cpp | 6 +++---
|
||||
1 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qapplication_x11.cpp b/src/gui/kernel/qapplication_x11.cpp
|
||||
index 33aec9e..53f020b 100644
|
||||
--- a/src/gui/kernel/qapplication_x11.cpp
|
||||
+++ b/src/gui/kernel/qapplication_x11.cpp
|
||||
@@ -1955,9 +1955,9 @@ void qt_init(QApplicationPrivate *priv, int,
|
||||
bool local = displayName.isEmpty() || displayName.lastIndexOf(QLatin1Char(':')) == 0;
|
||||
if (local && (qgetenv("QT_X11_NO_MITSHM").toInt() == 0)) {
|
||||
Visual *defaultVisual = DefaultVisual(X11->display, DefaultScreen(X11->display));
|
||||
- X11->use_mitshm = mitshm_pixmaps && (defaultVisual->red_mask == 0xff0000
|
||||
- && defaultVisual->green_mask == 0xff00
|
||||
- && defaultVisual->blue_mask == 0xff);
|
||||
+ X11->use_mitshm = defaultVisual->red_mask == 0xff0000
|
||||
+ && defaultVisual->green_mask == 0xff00
|
||||
+ && defaultVisual->blue_mask == 0xff;
|
||||
}
|
||||
}
|
||||
#endif // QT_NO_MITSHM
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
From 9eb3560cfd5cd0bc9c7bf79f2c27657ee07b8f95 Mon Sep 17 00:00:00 2001
|
||||
From: Albert Astals Cid <aacid@kde.org>
|
||||
Date: Sat, 8 Aug 2009 14:40:25 +0200
|
||||
Subject: [PATCH 12/13] Add context to tr calls in QShortcut
|
||||
|
||||
Some languages have special rules for using "+" to concatenate strings and
|
||||
for example it needs to be Ctrl + Shift instead of Ctrl+Shift, adding
|
||||
context to these strings helps creating a more correct translation
|
||||
---
|
||||
src/gui/kernel/qkeysequence.cpp | 20 ++++++++++----------
|
||||
1 files changed, 10 insertions(+), 10 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qkeysequence.cpp b/src/gui/kernel/qkeysequence.cpp
|
||||
index 894f663..c17f253 100644
|
||||
--- a/src/gui/kernel/qkeysequence.cpp
|
||||
+++ b/src/gui/kernel/qkeysequence.cpp
|
||||
@@ -991,10 +991,10 @@ int QKeySequencePrivate::decodeString(const QString &str, QKeySequence::Sequence
|
||||
|
||||
QList<QModifKeyName> modifs;
|
||||
if (nativeText) {
|
||||
- modifs << QModifKeyName(Qt::CTRL, QShortcut::tr("Ctrl").toLower().append(QLatin1Char('+')))
|
||||
- << QModifKeyName(Qt::SHIFT, QShortcut::tr("Shift").toLower().append(QLatin1Char('+')))
|
||||
- << QModifKeyName(Qt::ALT, QShortcut::tr("Alt").toLower().append(QLatin1Char('+')))
|
||||
- << QModifKeyName(Qt::META, QShortcut::tr("Meta").toLower().append(QLatin1Char('+')));
|
||||
+ modifs << QModifKeyName(Qt::CTRL, QShortcut::tr("Ctrl", "Ctrl key, used for shortcuts").toLower().append(QLatin1Char('+')))
|
||||
+ << QModifKeyName(Qt::SHIFT, QShortcut::tr("Shift", "Shift key, used for shortcuts").toLower().append(QLatin1Char('+')))
|
||||
+ << QModifKeyName(Qt::ALT, QShortcut::tr("Alt", "Alt key, used for shortcuts").toLower().append(QLatin1Char('+')))
|
||||
+ << QModifKeyName(Qt::META, QShortcut::tr("Meta", "Meta key, used for shortcuts").toLower().append(QLatin1Char('+')));
|
||||
}
|
||||
modifs += *gmodifs; // Test non-translated ones last
|
||||
|
||||
@@ -1086,7 +1086,7 @@ QString QKeySequence::encodeString(int key)
|
||||
static inline void addKey(QString &str, const QString &theKey, QKeySequence::SequenceFormat format)
|
||||
{
|
||||
if (!str.isEmpty())
|
||||
- str += (format == QKeySequence::NativeText) ? QShortcut::tr("+")
|
||||
+ str += (format == QKeySequence::NativeText) ? QShortcut::tr("+", "Symbol used to concatenate keys in shortcuts")
|
||||
: QString::fromLatin1("+");
|
||||
str += theKey;
|
||||
}
|
||||
@@ -1111,13 +1111,13 @@ QString QKeySequencePrivate::encodeString(int key, QKeySequence::SequenceFormat
|
||||
{
|
||||
// On other systems the order is Meta, Control, Alt, Shift
|
||||
if ((key & Qt::META) == Qt::META)
|
||||
- s = nativeText ? QShortcut::tr("Meta") : QString::fromLatin1("Meta");
|
||||
+ s = nativeText ? QShortcut::tr("Meta", "Meta key, used for shortcuts") : QString::fromLatin1("Meta");
|
||||
if ((key & Qt::CTRL) == Qt::CTRL)
|
||||
- addKey(s, nativeText ? QShortcut::tr("Ctrl") : QString::fromLatin1("Ctrl"), format);
|
||||
+ addKey(s, nativeText ? QShortcut::tr("Ctrl", "Ctrl key, used for shortcuts") : QString::fromLatin1("Ctrl"), format);
|
||||
if ((key & Qt::ALT) == Qt::ALT)
|
||||
- addKey(s, nativeText ? QShortcut::tr("Alt") : QString::fromLatin1("Alt"), format);
|
||||
+ addKey(s, nativeText ? QShortcut::tr("Alt", "Alt key, used for shortcuts") : QString::fromLatin1("Alt"), format);
|
||||
if ((key & Qt::SHIFT) == Qt::SHIFT)
|
||||
- addKey(s, nativeText ? QShortcut::tr("Shift") : QString::fromLatin1("Shift"), format);
|
||||
+ addKey(s, nativeText ? QShortcut::tr("Shift", "Shift key, used for shortcuts") : QString::fromLatin1("Shift"), format);
|
||||
}
|
||||
|
||||
|
||||
@@ -1132,7 +1132,7 @@ QString QKeySequencePrivate::encodeString(int key, QKeySequence::SequenceFormat
|
||||
p += QChar((key-0x10000)%400+0xdc00);
|
||||
}
|
||||
} else if (key >= Qt::Key_F1 && key <= Qt::Key_F35) {
|
||||
- p = nativeText ? QShortcut::tr("F%1").arg(key - Qt::Key_F1 + 1)
|
||||
+ p = nativeText ? QShortcut::tr("F%1", "Fx key, used for shortcuts").arg(key - Qt::Key_F1 + 1)
|
||||
: QString::fromLatin1("F%1").arg(key - Qt::Key_F1 + 1);
|
||||
} else if (key) {
|
||||
int i=0;
|
||||
--
|
||||
1.6.5.1
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
qt-bugs@ issue : none
|
||||
Trolltech task ID : none
|
||||
applied: yes
|
||||
author: David Faure <faure@kde.org>
|
||||
|
||||
Needed to distinguish qt-copy from released versions of qt, at least while
|
||||
we backport API additions to qt-copy.
|
||||
|
||||
Index: src/corelib/global/qglobal.h
|
||||
===================================================================
|
||||
--- src/corelib/global/qglobal.h (revision 536662)
|
||||
+++ src/corelib/global/qglobal.h (working copy)
|
||||
@@ -38,6 +38,11 @@
|
||||
#include <QtCore/qconfig.h>
|
||||
#endif
|
||||
|
||||
+/* QT_KDE_QT_COPY is set in qt-copy so that we know when we can use features backported to qt-copy
|
||||
+ Keep in mind that it should also work with the right release of Qt, so use something like:
|
||||
+ #if defined(QT_KDE_QT_COPY) || QT_VERSION >= 0x040200 */
|
||||
+#define QT_KDE_QT_COPY
|
||||
+
|
||||
/*
|
||||
The operating system, must be one of: (Q_OS_x)
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
qt-bugs@ issue : none
|
||||
Qt Software task ID : none
|
||||
bugs.kde.org number : none
|
||||
applied: no
|
||||
author: Aurélien Gâteau <agateau@kde.org>
|
||||
|
||||
Do not deduce scrollbar extent twice if scrollbar policy is
|
||||
Qt::ScrollBarAlwaysOn.
|
||||
|
||||
This patch has been merged in master but won't be in 4.5.
|
||||
http://qt.gitorious.org/qt/qt/merge_requests/432
|
||||
|
||||
--- src/gui/itemviews/qlistview.cpp
|
||||
+++ src/gui/itemviews/qlistview.cpp
|
||||
@@ -1969,10 +1969,16 @@ void QListViewPrivate::prepareItemsLayout()
|
||||
int frameAroundContents = 0;
|
||||
if (q->style()->styleHint(QStyle::SH_ScrollView_FrameOnlyAroundContents))
|
||||
frameAroundContents = q->style()->pixelMetric(QStyle::PM_DefaultFrameWidth) * 2;
|
||||
- int verticalMargin = vbarpolicy==Qt::ScrollBarAlwaysOff ? 0 :
|
||||
- q->style()->pixelMetric(QStyle::PM_ScrollBarExtent, 0, q->verticalScrollBar()) + frameAroundContents;
|
||||
- int horizontalMargin = hbarpolicy==Qt::ScrollBarAlwaysOff ? 0 :
|
||||
- q->style()->pixelMetric(QStyle::PM_ScrollBarExtent, 0, q->horizontalScrollBar()) + frameAroundContents;
|
||||
+
|
||||
+ // maximumViewportSize() already takes scrollbar into account if policy is
|
||||
+ // Qt::ScrollBarAlwaysOn but scrollbar extent must be deduced if policy
|
||||
+ // is Qt::ScrollBarAsNeeded
|
||||
+ int verticalMargin = vbarpolicy==Qt::ScrollBarAsNeeded
|
||||
+ ? q->style()->pixelMetric(QStyle::PM_ScrollBarExtent, 0, q->verticalScrollBar()) + frameAroundContents
|
||||
+ : 0;
|
||||
+ int horizontalMargin = hbarpolicy==Qt::ScrollBarAsNeeded
|
||||
+ ? q->style()->pixelMetric(QStyle::PM_ScrollBarExtent, 0, q->horizontalScrollBar()) + frameAroundContents
|
||||
+ : 0;
|
||||
|
||||
layoutBounds.adjust(0, 0, -verticalMargin, -horizontalMargin);
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
qt-bugs@ issue : unknows
|
||||
Qt Software task ID : 197802
|
||||
bugs.kde.org number : bugs on the issue not reported yed
|
||||
applied: no
|
||||
author: Marco Martin <notmart@gmail.com>
|
||||
|
||||
This patch makes children items of an hidden qgraphicsitem not be shown if show() is called on them. fixes several issues like the opensocial plasma widget and the Plasma desktop toolbox behaviour.
|
||||
|
||||
Index: src/gui/graphicsview/qgraphicsitem.cpp
|
||||
===================================================================
|
||||
--- src/gui/graphicsview/qgraphicsitem.cpp (revision 958522)
|
||||
+++ src/gui/graphicsview/qgraphicsitem.cpp (working copy)
|
||||
@@ -1522,6 +1522,11 @@
|
||||
if (visible == quint32(newVisible))
|
||||
return;
|
||||
|
||||
+ QGraphicsItem *parent(q_ptr->parentItem());
|
||||
+ if (parent && newVisible && !parent->d_ptr->visible) {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
// Modify the property.
|
||||
const QVariant newVisibleVariant(q_ptr->itemChange(QGraphicsItem::ItemVisibleChange,
|
||||
quint32(newVisible)));
|
|
@ -0,0 +1,44 @@
|
|||
From 0ebc9783d8ca0c4b27208bbc002c53c52c19ab4c Mon Sep 17 00:00:00 2001
|
||||
From: Bradley T. Hughes <bradley.hughes@nokia.com>
|
||||
Date: Tue, 4 May 2010 16:25:18 +0200
|
||||
Subject: [PATCH] Use qrand() instead of rand()
|
||||
|
||||
This only affects X11 code, and are the only 2 places in Qt where rand() is
|
||||
used instead of qrand().
|
||||
|
||||
Task-number: QTBUG-9793
|
||||
Reviewed-by: TrustMe
|
||||
---
|
||||
src/gui/kernel/qwidget_x11.cpp | 2 +-
|
||||
src/gui/painting/qpaintengine_x11.cpp | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qwidget_x11.cpp b/src/gui/kernel/qwidget_x11.cpp
|
||||
index 37ac6bf..43f510c 100644
|
||||
--- a/src/gui/kernel/qwidget_x11.cpp
|
||||
+++ b/src/gui/kernel/qwidget_x11.cpp
|
||||
@@ -3000,7 +3000,7 @@ Picture QX11Data::getSolidFill(int screen, const QColor &c)
|
||||
return X11->solid_fills[i].picture;
|
||||
}
|
||||
// none found, replace one
|
||||
- int i = rand() % 16;
|
||||
+ int i = qrand() % 16;
|
||||
|
||||
if (X11->solid_fills[i].screen != screen && X11->solid_fills[i].picture) {
|
||||
XRenderFreePicture (X11->display, X11->solid_fills[i].picture);
|
||||
diff --git a/src/gui/painting/qpaintengine_x11.cpp b/src/gui/painting/qpaintengine_x11.cpp
|
||||
index da48fcb..aef8b80 100644
|
||||
--- a/src/gui/painting/qpaintengine_x11.cpp
|
||||
+++ b/src/gui/painting/qpaintengine_x11.cpp
|
||||
@@ -315,7 +315,7 @@ static Picture getPatternFill(int screen, const QBrush &b)
|
||||
return X11->pattern_fills[i].picture;
|
||||
}
|
||||
// none found, replace one
|
||||
- int i = rand() % 16;
|
||||
+ int i = qrand() % 16;
|
||||
|
||||
if (X11->pattern_fills[i].screen != screen && X11->pattern_fills[i].picture) {
|
||||
XRenderFreePicture (X11->display, X11->pattern_fills[i].picture);
|
||||
--
|
||||
1.6.1
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
From 55ef01d93f8257b5927660290fc1ead0b2b74ec9 Mon Sep 17 00:00:00 2001
|
||||
From: Andreas Hartmetz <ahartmetz@gmail.com>
|
||||
Date: Thu, 18 Mar 2010 02:41:14 +0100
|
||||
Subject: [PATCH] Add environment variable switch for graphicssystem so distros and
|
||||
non-developers can more easily pick a different default.
|
||||
|
||||
---
|
||||
src/gui/kernel/qapplication.cpp | 4 ++++
|
||||
1 files changed, 4 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp
|
||||
index 49713cf..af83047 100644
|
||||
--- a/src/gui/kernel/qapplication.cpp
|
||||
+++ b/src/gui/kernel/qapplication.cpp
|
||||
@@ -763,6 +763,10 @@ void QApplicationPrivate::construct(
|
||||
|
||||
qt_is_gui_used = (qt_appType != QApplication::Tty);
|
||||
process_cmdline();
|
||||
+ // the environment variable has the lowest precedence of runtime graphicssystem switches
|
||||
+ if (graphics_system_name.isEmpty()) {
|
||||
+ graphics_system_name = QString::fromLocal8Bit(qgetenv("QT_GRAPHICSSYSTEM"));
|
||||
+ }
|
||||
// Must be called before initialize()
|
||||
qt_init(this, qt_appType
|
||||
#ifdef Q_WS_X11
|
||||
--
|
||||
1.6.1
|
||||
|
21
Makefile
21
Makefile
|
@ -1,21 +0,0 @@
|
|||
# Makefile for source rpm: qt
|
||||
# $Id$
|
||||
NAME := qt
|
||||
SPECFILE = $(firstword $(wildcard *.spec))
|
||||
|
||||
define find-makefile-common
|
||||
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
|
||||
endef
|
||||
|
||||
MAKEFILE_COMMON := $(shell $(find-makefile-common))
|
||||
|
||||
ifeq ($(MAKEFILE_COMMON),)
|
||||
# attempt a checkout
|
||||
define checkout-makefile-common
|
||||
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
|
||||
endef
|
||||
|
||||
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
|
||||
endif
|
||||
|
||||
include $(MAKEFILE_COMMON)
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,6 @@
|
|||
# quick-n-dirty method to fetch patches from -patched git branch
|
||||
# unfortunately, requires an already checked-out copy of the git repo
|
||||
|
||||
# when switching branches, use something like: git checkout --track remotes/origin/4.6-stable-patched
|
||||
git format-patch --output-directory kde-qt-patches v4.6.1..origin/4.6.1-patched
|
||||
|
|
@ -3,7 +3,7 @@ Name=Qt4 Linguist
|
|||
Comment=Add translations to Qt4 applications
|
||||
Exec=linguist-qt4
|
||||
Icon=linguist
|
||||
MimeType=application/x-linguist;
|
||||
MimeType=text/vnd.trolltech.linguist;application/x-linguist;
|
||||
Terminal=false
|
||||
Encoding=UTF-8
|
||||
Type=Application
|
||||
|
|
|
@ -1,60 +0,0 @@
|
|||
--- qt-x11-opensource-src-4.5.0/src/3rdparty/webkit/JavaScriptCore/wtf/Threading.h.orig 2009-03-15 00:21:08.000000000 -0500
|
||||
+++ qt-x11-opensource-src-4.5.0/src/3rdparty/webkit/JavaScriptCore/wtf/Threading.h 2009-03-15 00:22:38.000000000 -0500
|
||||
@@ -196,14 +196,14 @@
|
||||
#elif COMPILER(GCC)
|
||||
#define WTF_USE_LOCKFREE_THREADSAFESHARED 1
|
||||
|
||||
-inline void atomicIncrement(int volatile* addend) { __gnu_cxx::__atomic_add(addend, 1); }
|
||||
-inline int atomicDecrement(int volatile* addend) { return __gnu_cxx::__exchange_and_add(addend, -1) - 1; }
|
||||
+inline void atomicIncrement(_Atomic_word volatile* addend) { __gnu_cxx::__atomic_add(addend, 1); }
|
||||
+inline _Atomic_word atomicDecrement(_Atomic_word volatile* addend) { return __gnu_cxx::__exchange_and_add(addend, -1) - 1; }
|
||||
|
||||
#endif
|
||||
|
||||
template<class T> class ThreadSafeShared : Noncopyable {
|
||||
public:
|
||||
- ThreadSafeShared(int initialRefCount = 1)
|
||||
+ ThreadSafeShared(_Atomic_word initialRefCount = 1)
|
||||
: m_refCount(initialRefCount)
|
||||
{
|
||||
}
|
||||
@@ -237,16 +237,16 @@
|
||||
return refCount() == 1;
|
||||
}
|
||||
|
||||
- int refCount() const
|
||||
+ _Atomic_word refCount() const
|
||||
{
|
||||
#if !USE(LOCKFREE_THREADSAFESHARED)
|
||||
MutexLocker locker(m_mutex);
|
||||
#endif
|
||||
- return static_cast<int const volatile &>(m_refCount);
|
||||
+ return static_cast<_Atomic_word const volatile &>(m_refCount);
|
||||
}
|
||||
|
||||
private:
|
||||
- int m_refCount;
|
||||
+ _Atomic_word m_refCount;
|
||||
#if !USE(LOCKFREE_THREADSAFESHARED)
|
||||
mutable Mutex m_mutex;
|
||||
#endif
|
||||
--- qt-x11-opensource-src-4.5.0/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h.orig 2009-03-15 00:21:37.000000000 -0500
|
||||
+++ qt-x11-opensource-src-4.5.0/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h 2009-03-15 00:22:38.000000000 -0500
|
||||
@@ -214,9 +214,16 @@
|
||||
#endif
|
||||
|
||||
/* PLATFORM(SPARC64) */
|
||||
-#if defined(__sparc64__)
|
||||
+#if defined(__sparc64__) \
|
||||
+ || defined(__sparc__) && defined(_arch64__)
|
||||
#define WTF_PLATFORM_SPARC64 1
|
||||
#define WTF_PLATFORM_BIG_ENDIAN 1
|
||||
+#else
|
||||
+/* PLATFORM(SPARC) */
|
||||
+#if defined(__sparc__)
|
||||
+#define WTF_PLATFORM_SPARC 1
|
||||
+#define WTF_PLATFORM_BIG_ENDIAN 1
|
||||
+#endif
|
||||
#endif
|
||||
|
||||
/* PLATFORM(WIN_CE) && PLATFORM(QT)
|
|
@ -1,23 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
DATE=$(date +%Y%m%d)
|
||||
EXPORT_DIR=qt-copy
|
||||
|
||||
set -x
|
||||
rm -rf $EXPORT_DIR
|
||||
|
||||
# trunk tracking qt-4.5 now
|
||||
SVN_ROOT=svn://anonsvn.kde.org/home/kde/trunk/qt-copy
|
||||
|
||||
svn export --non-recursive $SVN_ROOT $EXPORT_DIR/
|
||||
svn export $SVN_ROOT/patches $EXPORT_DIR/patches
|
||||
|
||||
pushd $EXPORT_DIR
|
||||
rm -f ../qt-copy-patches-${DATE}svn.tar.bz2
|
||||
tar cjf ../qt-copy-patches-${DATE}svn.tar.bz2 \
|
||||
.applied_patches apply_patches README.qt-copy patches/
|
||||
popd
|
||||
|
||||
# cleanup
|
||||
rm -rf $EXPORT_DIR
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.0-beta1/tools/qdoc3/qdoc3.pro.qdoc3 qt-everywhere-opensource-src-4.6.0-beta1/tools/qdoc3/qdoc3.pro
|
||||
--- qt-everywhere-opensource-src-4.6.0-beta1/tools/qdoc3/qdoc3.pro.qdoc3 2009-10-13 10:34:08.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.6.0-beta1/tools/qdoc3/qdoc3.pro 2009-10-16 14:55:27.024789581 -0500
|
||||
@@ -105,3 +105,6 @@ SOURCES += apigenerator.cpp \
|
||||
webxmlgenerator.cpp \
|
||||
yyindent.cpp
|
||||
|
||||
+TARGET= qdoc3
|
||||
+target.path = $$[QT_INSTALL_BINS]
|
||||
+INSTALLS += target
|
||||
diff -up qt-everywhere-opensource-src-4.6.0-beta1/tools/tools.pro.qdoc3 qt-everywhere-opensource-src-4.6.0-beta1/tools/tools.pro
|
||||
--- qt-everywhere-opensource-src-4.6.0-beta1/tools/tools.pro.qdoc3 2009-10-13 10:34:08.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.6.0-beta1/tools/tools.pro 2009-10-16 14:57:49.699789384 -0500
|
||||
@@ -14,6 +14,7 @@ no-png {
|
||||
SUBDIRS += designer
|
||||
}
|
||||
SUBDIRS += linguist
|
||||
+ SUBDIRS += qdoc3
|
||||
symbian: SUBDIRS = designer
|
||||
wince*: SUBDIRS = qtestlib designer
|
||||
unix:!mac:!embedded:contains(QT_CONFIG, qt3support):SUBDIRS += qtconfig
|
|
@ -1,20 +1,20 @@
|
|||
diff -up qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/audiooutput.cpp.than qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/audiooutput.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/audiooutput.cpp.than 2009-08-16 14:20:43.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/audiooutput.cpp 2009-08-16 14:45:56.000000000 +0200
|
||||
@@ -141,7 +141,9 @@ bool AudioOutput::setOutputDevice(int ne
|
||||
diff -up qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/audiooutput.cpp.gst-pulsaudio qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/audiooutput.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/audiooutput.cpp.gst-pulsaudio 2009-11-27 02:27:50.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/audiooutput.cpp 2009-12-01 13:36:43.000000000 +0100
|
||||
@@ -148,7 +148,9 @@ bool AudioOutput::setOutputDevice(int ne
|
||||
// Save previous state
|
||||
GstState oldState = GST_STATE(m_audioSink);
|
||||
const QByteArray oldDeviceValue = GstHelper::property(m_audioSink, "device");
|
||||
- const QByteArray deviceId = deviceList.at(newDevice).gstId;
|
||||
+ const QByteArray deviceId = (deviceList.at(newDevice).gstId == "PulseAudio"
|
||||
+ ? "default"
|
||||
+ : deviceList.at(newDevice).gstId);
|
||||
- const QByteArray deviceId = deviceList.at(deviceIdx).gstId;
|
||||
+ const QByteArray deviceId = (deviceList.at(deviceIdx).gstId == "PulseAudio"
|
||||
+ ? "default"
|
||||
+ : deviceList.at(deviceIdx).gstId);
|
||||
m_device = newDevice;
|
||||
|
||||
// We test if the device can be opened by checking if it can go from NULL to READY state
|
||||
diff -up qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager.cpp.than qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager.cpp.than 2009-08-15 12:39:08.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager.cpp 2009-08-16 14:45:13.000000000 +0200
|
||||
diff -up qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/devicemanager.cpp.gst-pulsaudio qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/devicemanager.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/devicemanager.cpp.gst-pulsaudio 2009-11-27 02:27:50.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.0/src/3rdparty/phonon/gstreamer/devicemanager.cpp 2009-12-01 13:04:18.000000000 +0100
|
||||
@@ -50,6 +50,8 @@ AudioDevice::AudioDevice(DeviceManager *
|
||||
//get name from device
|
||||
if (gstId == "default") {
|
||||
|
@ -24,7 +24,7 @@ diff -up qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager
|
|||
} else {
|
||||
GstElement *aSink= manager->createAudioSink();
|
||||
|
||||
@@ -175,6 +177,18 @@ GstElement *DeviceManager::createAudioSi
|
||||
@@ -178,6 +180,18 @@ GstElement *DeviceManager::createAudioSi
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -43,7 +43,7 @@ diff -up qt-x11-opensource-src-4.5.2/src/3rdparty/phonon/gstreamer/devicemanager
|
|||
#ifdef USE_ALSASINK2
|
||||
if (!sink) {
|
||||
sink = gst_element_factory_make ("_k_alsasink", NULL);
|
||||
@@ -306,8 +320,12 @@ void DeviceManager::updateDeviceList()
|
||||
@@ -311,8 +325,12 @@ void DeviceManager::updateDeviceList()
|
||||
QList<QByteArray> list;
|
||||
|
||||
if (audioSink) {
|
|
@ -0,0 +1,84 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.2/src/gui/dialogs/qprintdialog_unix.cpp qt-everywhere-opensource-src-4.6.2-cups/src/gui/dialogs/qprintdialog_unix.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/gui/dialogs/qprintdialog_unix.cpp 2010-02-11 16:55:22.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2-cups/src/gui/dialogs/qprintdialog_unix.cpp 2010-02-28 04:34:16.000000000 +0100
|
||||
@@ -569,6 +569,32 @@
|
||||
void QPrintDialogPrivate::selectPrinter(QCUPSSupport *cups)
|
||||
{
|
||||
options.duplex->setEnabled(cups && cups->ppdOption("Duplex"));
|
||||
+
|
||||
+ if (cups) {
|
||||
+ const ppd_option_t* duplex = cups->ppdOption("Duplex");
|
||||
+ if (duplex) {
|
||||
+ // copy default ppd duplex to qt dialog
|
||||
+ if (qstrcmp(duplex->defchoice, "DuplexTumble") == 0)
|
||||
+ options.duplexShort->setChecked(true);
|
||||
+ else if (qstrcmp(duplex->defchoice, "DuplexNoTumble") == 0)
|
||||
+ options.duplexLong->setChecked(true);
|
||||
+ else
|
||||
+ options.noDuplex->setChecked(true);
|
||||
+ }
|
||||
+
|
||||
+ if (cups->currentPPD()) {
|
||||
+ // set default color
|
||||
+ if (cups->currentPPD()->color_device)
|
||||
+ options.color->setChecked(true);
|
||||
+ else
|
||||
+ options.grayscale->setChecked(true);
|
||||
+ }
|
||||
+
|
||||
+ // set collation
|
||||
+ const ppd_option_t *collate = cups->ppdOption("Collate");
|
||||
+ if (collate)
|
||||
+ options.collate->setChecked(qstrcmp(collate->defchoice, "True")==0);
|
||||
+ }
|
||||
}
|
||||
#endif
|
||||
|
||||
diff -ur qt-everywhere-opensource-src-4.6.2/src/gui/painting/qprinter.cpp qt-everywhere-opensource-src-4.6.2-cups/src/gui/painting/qprinter.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/gui/painting/qprinter.cpp 2010-02-11 16:55:22.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2-cups/src/gui/painting/qprinter.cpp 2010-02-28 04:55:15.000000000 +0100
|
||||
@@ -627,6 +627,44 @@
|
||||
&& d_ptr->paintEngine->type() != QPaintEngine::MacPrinter) {
|
||||
setOutputFormat(QPrinter::PdfFormat);
|
||||
}
|
||||
+
|
||||
+#if !defined(QT_NO_CUPS) && !defined(QT_NO_LIBRARY)
|
||||
+ // fill in defaults from ppd file
|
||||
+ QCUPSSupport cups;
|
||||
+
|
||||
+ int printernum = -1;
|
||||
+ for (int i = 0; i < cups.availablePrintersCount(); i++) {
|
||||
+ if (printerName().toLocal8Bit() == cups.availablePrinters()[i].name)
|
||||
+ printernum = i;
|
||||
+ }
|
||||
+ if (printernum >= 0) {
|
||||
+ cups.setCurrentPrinter(printernum);
|
||||
+
|
||||
+ const ppd_option_t* duplex = cups.ppdOption("Duplex");
|
||||
+ if (duplex) {
|
||||
+ // copy default ppd duplex to qt dialog
|
||||
+ if (qstrcmp(duplex->defchoice, "DuplexTumble") == 0)
|
||||
+ setDuplex(DuplexShortSide);
|
||||
+ else if (qstrcmp(duplex->defchoice, "DuplexNoTumble") == 0)
|
||||
+ setDuplex(DuplexLongSide);
|
||||
+ else
|
||||
+ setDuplex(DuplexNone);
|
||||
+ }
|
||||
+
|
||||
+ if (cups.currentPPD()) {
|
||||
+ // set default color
|
||||
+ if (cups.currentPPD()->color_device)
|
||||
+ setColorMode(Color);
|
||||
+ else
|
||||
+ setColorMode(GrayScale);
|
||||
+ }
|
||||
+
|
||||
+ // set collation
|
||||
+ const ppd_option_t *collate = cups.ppdOption("Collate");
|
||||
+ if (collate)
|
||||
+ setCollateCopies(qstrcmp(collate->defchoice, "True")==0);
|
||||
+ }
|
||||
+#endif
|
||||
}
|
||||
|
||||
/*!
|
|
@ -0,0 +1,267 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSGrammar.y.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSGrammar.y
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSGrammar.y.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSGrammar.y 2010-02-25 17:07:29.114742034 +0100
|
||||
@@ -416,7 +416,9 @@ valid_rule:
|
||||
;
|
||||
|
||||
rule:
|
||||
- valid_rule
|
||||
+ valid_rule {
|
||||
+ static_cast<CSSParser*>(parser)->m_hadSyntacticallyValidCSSRule = true;
|
||||
+ }
|
||||
| invalid_rule
|
||||
| invalid_at
|
||||
| invalid_import
|
||||
@@ -1517,8 +1519,12 @@ invalid_rule:
|
||||
;
|
||||
|
||||
invalid_block:
|
||||
- '{' error invalid_block_list error closing_brace
|
||||
- | '{' error closing_brace
|
||||
+ '{' error invalid_block_list error closing_brace {
|
||||
+ static_cast<CSSParser*>(parser)->invalidBlockHit();
|
||||
+ }
|
||||
+ | '{' error closing_brace {
|
||||
+ static_cast<CSSParser*>(parser)->invalidBlockHit();
|
||||
+ }
|
||||
;
|
||||
|
||||
invalid_block_list:
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp 2010-02-25 17:13:34.292803953 +0100
|
||||
@@ -25,6 +25,7 @@
|
||||
#include "CachedCSSStyleSheet.h"
|
||||
#include "DocLoader.h"
|
||||
#include "Document.h"
|
||||
+#include "SecurityOrigin.h"
|
||||
#include "MediaList.h"
|
||||
#include "Settings.h"
|
||||
#include <wtf/StdLibExtras.h>
|
||||
@@ -60,11 +61,21 @@ void CSSImportRule::setCSSStyleSheet(con
|
||||
m_styleSheet->setParent(0);
|
||||
m_styleSheet = CSSStyleSheet::create(this, url, charset);
|
||||
|
||||
+ bool crossOriginCSS = false;
|
||||
+ bool validMIMEType = false;
|
||||
CSSStyleSheet* parent = parentStyleSheet();
|
||||
bool strict = !parent || parent->useStrictParsing();
|
||||
- String sheetText = sheet->sheetText(strict);
|
||||
+ bool enforceMIMEType = strict;
|
||||
+
|
||||
+ String sheetText = sheet->sheetText(enforceMIMEType, &validMIMEType);
|
||||
m_styleSheet->parseString(sheetText, strict);
|
||||
|
||||
+ if (!parent || !parent->doc() || !parent->doc()->securityOrigin()->canRequest(KURL(ParsedURLString, url)))
|
||||
+ crossOriginCSS = true;
|
||||
+
|
||||
+ if (crossOriginCSS && !validMIMEType && !m_styleSheet->hasSyntacticallyValidCSSHeader())
|
||||
+ m_styleSheet = CSSStyleSheet::create(this, url, charset);
|
||||
+
|
||||
if (strict && parent && parent->doc() && parent->doc()->settings() && parent->doc()->settings()->needsSiteSpecificQuirks()) {
|
||||
// Work around <https://bugs.webkit.org/show_bug.cgi?id=28350>.
|
||||
DEFINE_STATIC_LOCAL(const String, slashKHTMLFixesDotCss, ("/KHTMLFixes.css"));
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-25 17:07:29.101741771 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.cpp 2010-02-25 17:07:29.117741744 +0100
|
||||
@@ -139,6 +139,7 @@ CSSParser::CSSParser(bool strictParsing)
|
||||
, m_currentShorthand(0)
|
||||
, m_implicitShorthand(false)
|
||||
, m_hasFontFaceOnlyValues(false)
|
||||
+ , m_hadSyntacticallyValidCSSRule(false)
|
||||
, m_defaultNamespace(starAtom)
|
||||
, m_data(0)
|
||||
, yy_start(1)
|
||||
@@ -5175,6 +5176,12 @@ WebKitCSSKeyframeRule* CSSParser::create
|
||||
return keyframePtr;
|
||||
}
|
||||
|
||||
+void CSSParser::invalidBlockHit()
|
||||
+{
|
||||
+ if (m_styleSheet && !m_hadSyntacticallyValidCSSRule)
|
||||
+ m_styleSheet->setHasSyntacticallyValidCSSHeader(false);
|
||||
+}
|
||||
+
|
||||
static int cssPropertyID(const UChar* propertyName, unsigned length)
|
||||
{
|
||||
if (!length)
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.h.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.h.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSParser.h 2010-02-25 17:07:29.117741744 +0100
|
||||
@@ -191,6 +191,7 @@ namespace WebCore {
|
||||
bool addVariableDeclarationBlock(const CSSParserString&);
|
||||
bool checkForVariables(CSSParserValueList*);
|
||||
void addUnresolvedProperty(int propId, bool important);
|
||||
+ void invalidBlockHit();
|
||||
|
||||
Vector<CSSSelector*>* reusableSelectorVector() { return &m_reusableSelectorVector; }
|
||||
|
||||
@@ -212,6 +213,7 @@ namespace WebCore {
|
||||
bool m_implicitShorthand;
|
||||
|
||||
bool m_hasFontFaceOnlyValues;
|
||||
+ bool m_hadSyntacticallyValidCSSRule;
|
||||
|
||||
Vector<String> m_variableNames;
|
||||
Vector<RefPtr<CSSValue> > m_variableValues;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp 2010-02-25 17:07:29.118741824 +0100
|
||||
@@ -41,6 +41,7 @@ CSSStyleSheet::CSSStyleSheet(CSSStyleShe
|
||||
, m_loadCompleted(false)
|
||||
, m_strictParsing(!parentSheet || parentSheet->useStrictParsing())
|
||||
, m_isUserStyleSheet(parentSheet ? parentSheet->isUserStyleSheet() : false)
|
||||
+ , m_hasSyntacticallyValidCSSHeader(true)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -52,6 +53,7 @@ CSSStyleSheet::CSSStyleSheet(Node* paren
|
||||
, m_loadCompleted(false)
|
||||
, m_strictParsing(false)
|
||||
, m_isUserStyleSheet(false)
|
||||
+ , m_hasSyntacticallyValidCSSHeader(true)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -61,6 +63,7 @@ CSSStyleSheet::CSSStyleSheet(CSSRule* ow
|
||||
, m_charset(charset)
|
||||
, m_loadCompleted(false)
|
||||
, m_strictParsing(!ownerRule || ownerRule->useStrictParsing())
|
||||
+ , m_hasSyntacticallyValidCSSHeader(true)
|
||||
{
|
||||
CSSStyleSheet* parentSheet = ownerRule ? ownerRule->parentStyleSheet() : 0;
|
||||
m_doc = parentSheet ? parentSheet->doc() : 0;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h 2010-02-25 17:07:29.118741824 +0100
|
||||
@@ -95,6 +95,8 @@ public:
|
||||
|
||||
void setIsUserStyleSheet(bool b) { m_isUserStyleSheet = b; }
|
||||
bool isUserStyleSheet() const { return m_isUserStyleSheet; }
|
||||
+ void setHasSyntacticallyValidCSSHeader(bool b) { m_hasSyntacticallyValidCSSHeader = b; }
|
||||
+ bool hasSyntacticallyValidCSSHeader() const { return m_hasSyntacticallyValidCSSHeader; }
|
||||
|
||||
private:
|
||||
CSSStyleSheet(Node* ownerNode, const String& href, const String& charset);
|
||||
@@ -110,6 +112,7 @@ private:
|
||||
bool m_loadCompleted : 1;
|
||||
bool m_strictParsing : 1;
|
||||
bool m_isUserStyleSheet : 1;
|
||||
+ bool m_hasSyntacticallyValidCSSHeader : 1;
|
||||
};
|
||||
|
||||
} // namespace
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp 2010-02-25 17:07:29.118741824 +0100
|
||||
@@ -203,7 +203,10 @@ void ProcessingInstruction::setCSSStyleS
|
||||
#endif
|
||||
RefPtr<CSSStyleSheet> newSheet = CSSStyleSheet::create(this, url, charset);
|
||||
m_sheet = newSheet;
|
||||
- parseStyleSheet(sheet->sheetText());
|
||||
+ // We don't need the cross-origin security check here because we are
|
||||
+ // getting the sheet text in "strict" mode. This enforces a valid CSS MIME
|
||||
+ // type.
|
||||
+ parseStyleSheet(sheet->sheetText(true));
|
||||
newSheet->setTitle(m_title);
|
||||
newSheet->setMedia(MediaList::create(newSheet.get(), m_media));
|
||||
newSheet->setDisabled(m_alternate);
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp 2010-02-25 17:07:29.119741915 +0100
|
||||
@@ -260,14 +260,27 @@ void HTMLLinkElement::setCSSStyleSheet(c
|
||||
bool strictParsing = !document()->inCompatMode();
|
||||
bool enforceMIMEType = strictParsing;
|
||||
|
||||
+ bool crossOriginCSS = false;
|
||||
+ bool validMIMEType = false;
|
||||
// Check to see if we should enforce the MIME type of the CSS resource in strict mode.
|
||||
// Running in iWeb 2 is one example of where we don't want to - <rdar://problem/6099748>
|
||||
if (enforceMIMEType && document()->page() && !document()->page()->settings()->enforceCSSMIMETypeInStrictMode())
|
||||
enforceMIMEType = false;
|
||||
|
||||
- String sheetText = sheet->sheetText(enforceMIMEType);
|
||||
+ String sheetText = sheet->sheetText(enforceMIMEType, &validMIMEType);
|
||||
m_sheet->parseString(sheetText, strictParsing);
|
||||
|
||||
+ // If we're loading a stylesheet cross-origin, and the MIME type is not
|
||||
+ // standard, require the CSS to at least start with a syntactically
|
||||
+ // valid CSS rule.
|
||||
+ // This prevents an attacker playing games by injecting CSS strings into
|
||||
+ // HTML, XML, JSON, etc. etc.
|
||||
+ if (!document()->securityOrigin()->canRequest(KURL(ParsedURLString, url)))
|
||||
+ crossOriginCSS = true;
|
||||
+
|
||||
+ if (crossOriginCSS && !validMIMEType && !m_sheet->hasSyntacticallyValidCSSHeader())
|
||||
+ m_sheet = CSSStyleSheet::create(this, url, charset);
|
||||
+
|
||||
if (strictParsing && document()->settings() && document()->settings()->needsSiteSpecificQuirks()) {
|
||||
// Work around <https://bugs.webkit.org/show_bug.cgi?id=28350>.
|
||||
DEFINE_STATIC_LOCAL(const String, slashKHTMLFixesDotCss, ("/KHTMLFixes.css"));
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp 2010-02-25 17:07:29.119741915 +0100
|
||||
@@ -71,11 +71,11 @@ String CachedCSSStyleSheet::encoding() c
|
||||
return m_decoder->encoding().name();
|
||||
}
|
||||
|
||||
-const String CachedCSSStyleSheet::sheetText(bool enforceMIMEType) const
|
||||
+const String CachedCSSStyleSheet::sheetText(bool enforceMIMEType, bool* hasValidMIMEType) const
|
||||
{
|
||||
ASSERT(!isPurgeable());
|
||||
|
||||
- if (!m_data || m_data->isEmpty() || !canUseSheet(enforceMIMEType))
|
||||
+ if (!m_data || m_data->isEmpty() || !canUseSheet(enforceMIMEType, hasValidMIMEType))
|
||||
return String();
|
||||
|
||||
if (!m_decodedSheetText.isNull())
|
||||
@@ -122,12 +122,12 @@ void CachedCSSStyleSheet::error()
|
||||
checkNotify();
|
||||
}
|
||||
|
||||
-bool CachedCSSStyleSheet::canUseSheet(bool enforceMIMEType) const
|
||||
+bool CachedCSSStyleSheet::canUseSheet(bool enforceMIMEType, bool* hasValidMIMEType) const
|
||||
{
|
||||
if (errorOccurred())
|
||||
return false;
|
||||
|
||||
- if (!enforceMIMEType)
|
||||
+ if (!enforceMIMEType && !hasValidMIMEType)
|
||||
return true;
|
||||
|
||||
// This check exactly matches Firefox. Note that we grab the Content-Type
|
||||
@@ -138,7 +138,12 @@ bool CachedCSSStyleSheet::canUseSheet(bo
|
||||
// This code defaults to allowing the stylesheet for non-HTTP protocols so
|
||||
// folks can use standards mode for local HTML documents.
|
||||
String mimeType = extractMIMETypeFromMediaType(response().httpHeaderField("Content-Type"));
|
||||
- return mimeType.isEmpty() || equalIgnoringCase(mimeType, "text/css") || equalIgnoringCase(mimeType, "application/x-unknown-content-type");
|
||||
+ bool typeOK = mimeType.isEmpty() || equalIgnoringCase(mimeType, "text/css") || equalIgnoringCase(mimeType, "application/x-unknown-content-type");
|
||||
+ if (hasValidMIMEType)
|
||||
+ *hasValidMIMEType = typeOK;
|
||||
+ if (!enforceMIMEType)
|
||||
+ return true;
|
||||
+ return typeOK;
|
||||
}
|
||||
|
||||
}
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.h.cve-2010-0051-lax-css-parsing-cross-domain-theft qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.h.cve-2010-0051-lax-css-parsing-cross-domain-theft 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.h 2010-02-25 17:07:29.120741848 +0100
|
||||
@@ -40,7 +40,7 @@ namespace WebCore {
|
||||
CachedCSSStyleSheet(const String& URL, const String& charset);
|
||||
virtual ~CachedCSSStyleSheet();
|
||||
|
||||
- const String sheetText(bool enforceMIMEType = true) const;
|
||||
+ const String sheetText(bool enforceMIMEType = true, bool* hasValidMIMEType = 0) const;
|
||||
|
||||
virtual void didAddClient(CachedResourceClient*);
|
||||
|
||||
@@ -56,7 +56,7 @@ namespace WebCore {
|
||||
void checkNotify();
|
||||
|
||||
private:
|
||||
- bool canUseSheet(bool enforceMIMEType) const;
|
||||
+ bool canUseSheet(bool enforceMIMEType, bool* hasValidMIMEType) const;
|
||||
|
||||
protected:
|
||||
RefPtr<TextResourceDecoder> m_decoder;
|
|
@ -0,0 +1,782 @@
|
|||
diff -U0 qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/ChangeLog.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/ChangeLog
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/ChangeLog.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/ChangeLog 2010-05-03 15:55:37.703101680 +0200
|
||||
@@ -0,0 +1,90 @@
|
||||
+2010-01-20 Adam Barth <abarth@webkit.org>
|
||||
+
|
||||
+ Reviewed by Darin Adler.
|
||||
+
|
||||
+ Stylesheet href property shows redirected URL unlike other browsers
|
||||
+ https://bugs.webkit.org/show_bug.cgi?id=33683
|
||||
+
|
||||
+ Teach StyleSheet the difference between original and final URLs in
|
||||
+ redirect chains. Unfortunately, StyleSheet needs to know both of these
|
||||
+ URLs. The original URL is needed for the href property and the final
|
||||
+ URL is needed as the baseURL.
|
||||
+
|
||||
+ This change required touching a lot of lines of code because we need to
|
||||
+ plumb this information to the StyleSheet object. I audited all
|
||||
+ existing clients of href() and setHref() to see whether they wanted the
|
||||
+ original or final URLs. I then updated the clients (except the JS
|
||||
+ bindings themselves) to use the correct accessor.
|
||||
+
|
||||
+ Test: http/tests/security/stylesheet-href-redirect.html
|
||||
+
|
||||
+ * css/CSSImportRule.cpp:
|
||||
+ (WebCore::CSSImportRule::setCSSStyleSheet):
|
||||
+ (WebCore::CSSImportRule::insertedIntoParent):
|
||||
+ * css/CSSImportRule.h:
|
||||
+ * css/CSSStyleSheet.cpp:
|
||||
+ (WebCore::CSSStyleSheet::CSSStyleSheet):
|
||||
+ * css/CSSStyleSheet.h:
|
||||
+ (WebCore::CSSStyleSheet::create):
|
||||
+ (WebCore::CSSStyleSheet::createInline): Added a new constructor to deal
|
||||
+ with "inline" style sheets that don't have a distinct original and
|
||||
+ final URL.
|
||||
+ * css/StyleBase.cpp:
|
||||
+ (WebCore::StyleBase::baseURL): This code wants to use the final URL,
|
||||
+ not the original URL. Updated it to grab the baseURL directly.
|
||||
+ * css/StyleSheet.cpp:
|
||||
+ (WebCore::StyleSheet::StyleSheet):
|
||||
+ * css/StyleSheet.h:
|
||||
+ (WebCore::StyleSheet::href):
|
||||
+ (WebCore::StyleSheet::setBaseURL): This function really just updates
|
||||
+ the base URL of the style sheet, so I made it more explicit.
|
||||
+ (WebCore::StyleSheet::putativeBaseURL): We need an accessor for the
|
||||
+ base URL, but baseURL is already taken.
|
||||
+ * dom/Document.cpp:
|
||||
+ (WebCore::Document::updateBaseURL):
|
||||
+ (WebCore::Document::pageUserSheet):
|
||||
+ (WebCore::Document::pageGroupUserSheets):
|
||||
+ (WebCore::Document::elementSheet):
|
||||
+ (WebCore::Document::mappedElementSheet):
|
||||
+ * dom/ProcessingInstruction.cpp:
|
||||
+ (WebCore::ProcessingInstruction::checkStyleSheet):
|
||||
+ (WebCore::ProcessingInstruction::setCSSStyleSheet):
|
||||
+ (WebCore::ProcessingInstruction::setXSLStyleSheet):
|
||||
+ * dom/ProcessingInstruction.h:
|
||||
+ * dom/StyleElement.cpp:
|
||||
+ (WebCore::StyleElement::createSheet):
|
||||
+ * html/HTMLLinkElement.cpp:
|
||||
+ (WebCore::HTMLLinkElement::setCSSStyleSheet):
|
||||
+ * html/HTMLLinkElement.h:
|
||||
+ * loader/CachedCSSStyleSheet.cpp:
|
||||
+ (WebCore::CachedCSSStyleSheet::didAddClient):
|
||||
+ (WebCore::CachedCSSStyleSheet::checkNotify): This code now passes both
|
||||
+ the original and final URL into setCSSStyleSheet so that the style
|
||||
+ sheet can have both.
|
||||
+ * loader/CachedResourceClient.h:
|
||||
+ (WebCore::CachedResourceClient::setCSSStyleSheet):
|
||||
+ (WebCore::CachedResourceClient::setXSLStyleSheet):
|
||||
+ * loader/CachedXSLStyleSheet.cpp:
|
||||
+ (WebCore::CachedXSLStyleSheet::didAddClient):
|
||||
+ (WebCore::CachedXSLStyleSheet::checkNotify): I don't have any direct
|
||||
+ evidence that we need to change the XSLStyleSheet behavior, which is
|
||||
+ why I wasn't able to add a test for the behavior. However, the objects
|
||||
+ are parallel enough that it seemed like the right thing to do.
|
||||
+ * xml/XSLImportRule.cpp:
|
||||
+ (WebCore::XSLImportRule::setXSLStyleSheet):
|
||||
+ (WebCore::XSLImportRule::loadSheet):
|
||||
+ * xml/XSLImportRule.h:
|
||||
+ * xml/XSLStyleSheet.h:
|
||||
+ (WebCore::XSLStyleSheet::create):
|
||||
+ (WebCore::XSLStyleSheet::createEmbedded):
|
||||
+ * xml/XSLStyleSheetLibxslt.cpp:
|
||||
+ (WebCore::XSLStyleSheet::XSLStyleSheet):
|
||||
+ (WebCore::XSLStyleSheet::parseString):
|
||||
+ (WebCore::XSLStyleSheet::loadChildSheets):
|
||||
+ * xml/XSLStyleSheetQt.cpp:
|
||||
+ (WebCore::XSLStyleSheet::XSLStyleSheet):
|
||||
+ * xml/XSLTProcessorLibxslt.cpp:
|
||||
+ (WebCore::xsltStylesheetPointer):
|
||||
+ * xml/XSLTProcessorQt.cpp:
|
||||
+ (WebCore::XSLTProcessor::transformToString):
|
||||
+
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.652102626 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.cpp 2010-05-03 16:49:14.631038884 +0200
|
||||
@@ -55,11 +55,11 @@ CSSImportRule::~CSSImportRule()
|
||||
m_cachedSheet->removeClient(this);
|
||||
}
|
||||
|
||||
-void CSSImportRule::setCSSStyleSheet(const String& url, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
+void CSSImportRule::setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
{
|
||||
if (m_styleSheet)
|
||||
m_styleSheet->setParent(0);
|
||||
- m_styleSheet = CSSStyleSheet::create(this, url, charset);
|
||||
+ m_styleSheet = CSSStyleSheet::create(this, href, baseURL, charset);
|
||||
|
||||
bool crossOriginCSS = false;
|
||||
bool validMIMEType = false;
|
||||
@@ -70,17 +70,17 @@ void CSSImportRule::setCSSStyleSheet(con
|
||||
String sheetText = sheet->sheetText(enforceMIMEType, &validMIMEType);
|
||||
m_styleSheet->parseString(sheetText, strict);
|
||||
|
||||
- if (!parent || !parent->doc() || !parent->doc()->securityOrigin()->canRequest(KURL(ParsedURLString, url)))
|
||||
+ if (!parent || !parent->doc() || !parent->doc()->securityOrigin()->canRequest(baseURL))
|
||||
crossOriginCSS = true;
|
||||
|
||||
if (crossOriginCSS && !validMIMEType && !m_styleSheet->hasSyntacticallyValidCSSHeader())
|
||||
- m_styleSheet = CSSStyleSheet::create(this, url, charset);
|
||||
+ m_styleSheet = CSSStyleSheet::create(this, href, baseURL, charset);
|
||||
|
||||
if (strict && parent && parent->doc() && parent->doc()->settings() && parent->doc()->settings()->needsSiteSpecificQuirks()) {
|
||||
// Work around <https://bugs.webkit.org/show_bug.cgi?id=28350>.
|
||||
DEFINE_STATIC_LOCAL(const String, slashKHTMLFixesDotCss, ("/KHTMLFixes.css"));
|
||||
DEFINE_STATIC_LOCAL(const String, mediaWikiKHTMLFixesStyleSheet, ("/* KHTML fix stylesheet */\n/* work around the horizontal scrollbars */\n#column-content { margin-left: 0; }\n\n"));
|
||||
- if (url.endsWith(slashKHTMLFixesDotCss) && sheetText == mediaWikiKHTMLFixesStyleSheet) {
|
||||
+ if (baseURL.string().endsWith(slashKHTMLFixesDotCss) && sheetText == mediaWikiKHTMLFixesStyleSheet) {
|
||||
ASSERT(m_styleSheet->length() == 1);
|
||||
ExceptionCode ec;
|
||||
m_styleSheet->deleteRule(0, ec);
|
||||
@@ -109,15 +109,16 @@ void CSSImportRule::insertedIntoParent()
|
||||
return;
|
||||
|
||||
String absHref = m_strHref;
|
||||
- if (!parentSheet->href().isNull())
|
||||
+ if (!parentSheet->putativeBaseURL().isNull())
|
||||
// use parent styleheet's URL as the base URL
|
||||
- absHref = KURL(KURL(ParsedURLString, parentSheet->href()), m_strHref).string();
|
||||
+ absHref = KURL(parentSheet->putativeBaseURL(), m_strHref).string();
|
||||
|
||||
// Check for a cycle in our import chain. If we encounter a stylesheet
|
||||
// in our parent chain with the same URL, then just bail.
|
||||
StyleBase* root = this;
|
||||
for (StyleBase* curr = parent(); curr; curr = curr->parent()) {
|
||||
- if (curr->isCSSStyleSheet() && absHref == static_cast<CSSStyleSheet*>(curr)->href())
|
||||
+ // FIXME: This is wrong if the putativeBaseURL was updated via document::updateBaseURL.
|
||||
+ if (curr->isCSSStyleSheet() && absHref == static_cast<CSSStyleSheet*>(curr)->putativeBaseURL().string())
|
||||
return;
|
||||
root = curr;
|
||||
}
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSImportRule.h 2010-05-03 15:55:37.740976769 +0200
|
||||
@@ -63,7 +63,7 @@ private:
|
||||
virtual unsigned short type() const { return IMPORT_RULE; }
|
||||
|
||||
// from CachedResourceClient
|
||||
- virtual void setCSSStyleSheet(const String& url, const String& charset, const CachedCSSStyleSheet*);
|
||||
+ virtual void setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet*);
|
||||
|
||||
String m_strHref;
|
||||
RefPtr<MediaList> m_lstMedia;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.660977242 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.cpp 2010-05-03 15:55:37.740976769 +0200
|
||||
@@ -33,8 +33,8 @@
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
-CSSStyleSheet::CSSStyleSheet(CSSStyleSheet* parentSheet, const String& href, const String& charset)
|
||||
- : StyleSheet(parentSheet, href)
|
||||
+CSSStyleSheet::CSSStyleSheet(CSSStyleSheet* parentSheet, const String& href, const KURL& baseURL, const String& charset)
|
||||
+ : StyleSheet(parentSheet, href, baseURL)
|
||||
, m_doc(parentSheet ? parentSheet->doc() : 0)
|
||||
, m_namespaces(0)
|
||||
, m_charset(charset)
|
||||
@@ -45,8 +45,8 @@ CSSStyleSheet::CSSStyleSheet(CSSStyleShe
|
||||
{
|
||||
}
|
||||
|
||||
-CSSStyleSheet::CSSStyleSheet(Node* parentNode, const String& href, const String& charset)
|
||||
- : StyleSheet(parentNode, href)
|
||||
+CSSStyleSheet::CSSStyleSheet(Node* parentNode, const String& href, const KURL& baseURL, const String& charset)
|
||||
+ : StyleSheet(parentNode, href, baseURL)
|
||||
, m_doc(parentNode->document())
|
||||
, m_namespaces(0)
|
||||
, m_charset(charset)
|
||||
@@ -57,8 +57,8 @@ CSSStyleSheet::CSSStyleSheet(Node* paren
|
||||
{
|
||||
}
|
||||
|
||||
-CSSStyleSheet::CSSStyleSheet(CSSRule* ownerRule, const String& href, const String& charset)
|
||||
- : StyleSheet(ownerRule, href)
|
||||
+CSSStyleSheet::CSSStyleSheet(CSSRule* ownerRule, const String& href, const KURL& baseURL, const String& charset)
|
||||
+ : StyleSheet(ownerRule, href, baseURL)
|
||||
, m_namespaces(0)
|
||||
, m_charset(charset)
|
||||
, m_loadCompleted(false)
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.660977242 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/CSSStyleSheet.h 2010-05-03 15:55:37.745101706 +0200
|
||||
@@ -38,27 +38,31 @@ class CSSStyleSheet : public StyleSheet
|
||||
public:
|
||||
static PassRefPtr<CSSStyleSheet> create()
|
||||
{
|
||||
- return adoptRef(new CSSStyleSheet(static_cast<CSSStyleSheet*>(0), String(), String()));
|
||||
+ return adoptRef(new CSSStyleSheet(static_cast<CSSStyleSheet*>(0), String(), KURL(), String()));
|
||||
}
|
||||
static PassRefPtr<CSSStyleSheet> create(Node* ownerNode)
|
||||
{
|
||||
- return adoptRef(new CSSStyleSheet(ownerNode, String(), String()));
|
||||
+ return adoptRef(new CSSStyleSheet(ownerNode, String(), KURL(), String()));
|
||||
}
|
||||
- static PassRefPtr<CSSStyleSheet> create(Node* ownerNode, const String& href)
|
||||
+ static PassRefPtr<CSSStyleSheet> create(Node* ownerNode, const String& href, const KURL& baseURL)
|
||||
{
|
||||
- return adoptRef(new CSSStyleSheet(ownerNode, href, String()));
|
||||
+ return adoptRef(new CSSStyleSheet(ownerNode, href, baseURL, String()));
|
||||
}
|
||||
- static PassRefPtr<CSSStyleSheet> create(Node* ownerNode, const String& href, const String& charset)
|
||||
+ static PassRefPtr<CSSStyleSheet> create(Node* ownerNode, const String& href, const KURL& baseURL, const String& charset)
|
||||
{
|
||||
- return adoptRef(new CSSStyleSheet(ownerNode, href, charset));
|
||||
+ return adoptRef(new CSSStyleSheet(ownerNode, href, baseURL, charset));
|
||||
}
|
||||
- static PassRefPtr<CSSStyleSheet> create(CSSRule* ownerRule, const String& href, const String& charset)
|
||||
+ static PassRefPtr<CSSStyleSheet> create(CSSRule* ownerRule, const String& href, const KURL& baseURL, const String& charset)
|
||||
{
|
||||
- return adoptRef(new CSSStyleSheet(ownerRule, href, charset));
|
||||
+ return adoptRef(new CSSStyleSheet(ownerRule, href, baseURL, charset));
|
||||
+ }
|
||||
+ static PassRefPtr<CSSStyleSheet> createInline(Node* ownerNode, const KURL& baseURL)
|
||||
+ {
|
||||
+ return adoptRef(new CSSStyleSheet(ownerNode, baseURL.string(), baseURL, String()));
|
||||
}
|
||||
|
||||
virtual ~CSSStyleSheet();
|
||||
-
|
||||
+
|
||||
CSSRule* ownerRule() const;
|
||||
PassRefPtr<CSSRuleList> cssRules(bool omitCharsetRules = false);
|
||||
unsigned insertRule(const String& rule, unsigned index, ExceptionCode&);
|
||||
@@ -72,7 +76,7 @@ public:
|
||||
|
||||
void addNamespace(CSSParser*, const AtomicString& prefix, const AtomicString& uri);
|
||||
const AtomicString& determineNamespace(const AtomicString& prefix);
|
||||
-
|
||||
+
|
||||
virtual void styleSheetChanged();
|
||||
|
||||
virtual bool parseString(const String&, bool strict = true);
|
||||
@@ -99,10 +103,10 @@ public:
|
||||
bool hasSyntacticallyValidCSSHeader() const { return m_hasSyntacticallyValidCSSHeader; }
|
||||
|
||||
private:
|
||||
- CSSStyleSheet(Node* ownerNode, const String& href, const String& charset);
|
||||
- CSSStyleSheet(CSSStyleSheet* parentSheet, const String& href, const String& charset);
|
||||
- CSSStyleSheet(CSSRule* ownerRule, const String& href, const String& charset);
|
||||
-
|
||||
+ CSSStyleSheet(Node* ownerNode, const String& href, const KURL& baseURL, const String& charset);
|
||||
+ CSSStyleSheet(CSSStyleSheet* parentSheet, const String& href, const KURL& baseURL, const String& charset);
|
||||
+ CSSStyleSheet(CSSRule* ownerRule, const String& href, const KURL& baseURL, const String& charset);
|
||||
+
|
||||
virtual bool isCSSStyleSheet() const { return true; }
|
||||
virtual String type() const { return "text/css"; }
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleBase.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleBase.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleBase.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleBase.cpp 2010-05-03 15:55:37.757976382 +0200
|
||||
@@ -56,9 +56,9 @@ KURL StyleBase::baseURL() const
|
||||
StyleSheet* sheet = const_cast<StyleBase*>(this)->stylesheet();
|
||||
if (!sheet)
|
||||
return KURL();
|
||||
- if (!sheet->href().isNull())
|
||||
- return KURL(ParsedURLString, sheet->href());
|
||||
- if (sheet->parent())
|
||||
+ if (!sheet->putativeBaseURL().isNull())
|
||||
+ return sheet->putativeBaseURL();
|
||||
+ if (sheet->parent())
|
||||
return sheet->parent()->baseURL();
|
||||
if (!sheet->ownerNode())
|
||||
return KURL();
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.cpp 2010-05-03 15:55:37.758976847 +0200
|
||||
@@ -26,27 +26,30 @@
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
-StyleSheet::StyleSheet(StyleSheet* parentSheet, const String& href)
|
||||
+StyleSheet::StyleSheet(StyleSheet* parentSheet, const String& href, const KURL& baseURL)
|
||||
: StyleList(parentSheet)
|
||||
, m_parentNode(0)
|
||||
- , m_strHref(href)
|
||||
+ , m_href(href)
|
||||
+ , m_baseURL(baseURL)
|
||||
, m_disabled(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
-StyleSheet::StyleSheet(Node* parentNode, const String& href)
|
||||
+StyleSheet::StyleSheet(Node* parentNode, const String& href, const KURL& baseURL)
|
||||
: StyleList(0)
|
||||
, m_parentNode(parentNode)
|
||||
- , m_strHref(href)
|
||||
+ , m_href(href)
|
||||
+ , m_baseURL(baseURL)
|
||||
, m_disabled(false)
|
||||
{
|
||||
}
|
||||
|
||||
-StyleSheet::StyleSheet(StyleBase* owner, const String& href)
|
||||
+StyleSheet::StyleSheet(StyleBase* owner, const String& href, const KURL& baseURL)
|
||||
: StyleList(owner)
|
||||
, m_parentNode(0)
|
||||
- , m_strHref(href)
|
||||
+ , m_href(href)
|
||||
+ , m_baseURL(baseURL)
|
||||
, m_disabled(false)
|
||||
{
|
||||
}
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/css/StyleSheet.h 2010-05-03 15:55:37.758976847 +0200
|
||||
@@ -41,8 +41,18 @@ public:
|
||||
|
||||
Node* ownerNode() const { return m_parentNode; }
|
||||
StyleSheet *parentStyleSheet() const;
|
||||
- const String& href() const { return m_strHref; }
|
||||
- void setHref(const String& href) { m_strHref = href; }
|
||||
+
|
||||
+ // Note that href is the URL that started the redirect chain that led to
|
||||
+ // this style sheet. This property probably isn't useful for much except
|
||||
+ // the JavaScript binding (which needs to use this value for security).
|
||||
+ const String& href() const { return m_href; }
|
||||
+
|
||||
+ void setBaseURL(const KURL& baseURL) { m_baseURL = baseURL; }
|
||||
+
|
||||
+ // Notice that this object inherits a baseURL function from StyleBase that
|
||||
+ // crawls the parent() relation looking for a non-0 putativeBaseURL.
|
||||
+ const KURL& putativeBaseURL() const { return m_baseURL; }
|
||||
+
|
||||
const String& title() const { return m_strTitle; }
|
||||
void setTitle(const String& s) { m_strTitle = s; }
|
||||
MediaList* media() const { return m_media.get(); }
|
||||
@@ -58,15 +68,16 @@ public:
|
||||
virtual bool parseString(const String&, bool strict = true) = 0;
|
||||
|
||||
protected:
|
||||
- StyleSheet(Node* ownerNode, const String& href);
|
||||
- StyleSheet(StyleSheet* parentSheet, const String& href);
|
||||
- StyleSheet(StyleBase* owner, const String& href);
|
||||
+ StyleSheet(Node* ownerNode, const String& href, const KURL& baseURL);
|
||||
+ StyleSheet(StyleSheet* parentSheet, const String& href, const KURL& baseURL);
|
||||
+ StyleSheet(StyleBase* owner, const String& href, const KURL& baseURL);
|
||||
|
||||
private:
|
||||
virtual bool isStyleSheet() const { return true; }
|
||||
|
||||
Node* m_parentNode;
|
||||
- String m_strHref;
|
||||
+ String m_href;
|
||||
+ KURL m_baseURL;
|
||||
String m_strTitle;
|
||||
RefPtr<MediaList> m_media;
|
||||
bool m_disabled;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/Document.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/Document.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/Document.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/Document.cpp 2010-05-03 15:55:37.760977901 +0200
|
||||
@@ -1920,9 +1920,9 @@ void Document::updateBaseURL()
|
||||
m_baseURL = KURL();
|
||||
|
||||
if (m_elemSheet)
|
||||
- m_elemSheet->setHref(m_baseURL.string());
|
||||
+ m_elemSheet->setBaseURL(m_baseURL);
|
||||
if (m_mappedElementSheet)
|
||||
- m_mappedElementSheet->setHref(m_baseURL.string());
|
||||
+ m_mappedElementSheet->setBaseURL(m_baseURL);
|
||||
}
|
||||
|
||||
String Document::userAgent(const KURL& url) const
|
||||
@@ -1944,7 +1944,7 @@ CSSStyleSheet* Document::pageUserSheet()
|
||||
return 0;
|
||||
|
||||
// Parse the sheet and cache it.
|
||||
- m_pageUserSheet = CSSStyleSheet::create(this, settings()->userStyleSheetLocation());
|
||||
+ m_pageUserSheet = CSSStyleSheet::createInline(this, settings()->userStyleSheetLocation());
|
||||
m_pageUserSheet->setIsUserStyleSheet(true);
|
||||
m_pageUserSheet->parseString(userSheetText, !inCompatMode());
|
||||
return m_pageUserSheet.get();
|
||||
@@ -1979,7 +1979,7 @@ const Vector<RefPtr<CSSStyleSheet> >* Do
|
||||
const UserStyleSheet* sheet = sheets->at(i).get();
|
||||
if (!UserContentURLPattern::matchesPatterns(url(), sheet->whitelist(), sheet->blacklist()))
|
||||
continue;
|
||||
- RefPtr<CSSStyleSheet> parsedSheet = CSSStyleSheet::create(const_cast<Document*>(this), sheet->url());
|
||||
+ RefPtr<CSSStyleSheet> parsedSheet = CSSStyleSheet::createInline(const_cast<Document*>(this), sheet->url());
|
||||
parsedSheet->setIsUserStyleSheet(true);
|
||||
parsedSheet->parseString(sheet->source(), !inCompatMode());
|
||||
if (!m_pageGroupUserSheets)
|
||||
@@ -2001,14 +2001,14 @@ void Document::clearPageGroupUserSheets(
|
||||
CSSStyleSheet* Document::elementSheet()
|
||||
{
|
||||
if (!m_elemSheet)
|
||||
- m_elemSheet = CSSStyleSheet::create(this, m_baseURL.string());
|
||||
+ m_elemSheet = CSSStyleSheet::createInline(this, m_baseURL);
|
||||
return m_elemSheet.get();
|
||||
}
|
||||
|
||||
CSSStyleSheet* Document::mappedElementSheet()
|
||||
{
|
||||
if (!m_mappedElementSheet)
|
||||
- m_mappedElementSheet = CSSStyleSheet::create(this, m_baseURL.string());
|
||||
+ m_mappedElementSheet = CSSStyleSheet::createInline(this, m_baseURL);
|
||||
return m_mappedElementSheet.get();
|
||||
}
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.661976647 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.cpp 2010-05-03 15:55:37.761977599 +0200
|
||||
@@ -138,7 +138,8 @@ void ProcessingInstruction::checkStyleSh
|
||||
// We need to make a synthetic XSLStyleSheet that is embedded. It needs to be able
|
||||
// to kick off import/include loads that can hang off some parent sheet.
|
||||
if (m_isXSL) {
|
||||
- m_sheet = XSLStyleSheet::createEmbedded(this, m_localHref);
|
||||
+ KURL baseURL = KURL(ParsedURLString, m_localHref);
|
||||
+ m_sheet = XSLStyleSheet::createEmbedded(this, m_localHref, baseURL);
|
||||
m_loading = false;
|
||||
}
|
||||
#endif
|
||||
@@ -196,12 +197,12 @@ bool ProcessingInstruction::sheetLoaded(
|
||||
return false;
|
||||
}
|
||||
|
||||
-void ProcessingInstruction::setCSSStyleSheet(const String& url, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
+void ProcessingInstruction::setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
{
|
||||
#if ENABLE(XSLT)
|
||||
ASSERT(!m_isXSL);
|
||||
#endif
|
||||
- RefPtr<CSSStyleSheet> newSheet = CSSStyleSheet::create(this, url, charset);
|
||||
+ RefPtr<CSSStyleSheet> newSheet = CSSStyleSheet::create(this, href, baseURL, charset);
|
||||
m_sheet = newSheet;
|
||||
// We don't need the cross-origin security check here because we are
|
||||
// getting the sheet text in "strict" mode. This enforces a valid CSS MIME
|
||||
@@ -213,10 +214,10 @@ void ProcessingInstruction::setCSSStyleS
|
||||
}
|
||||
|
||||
#if ENABLE(XSLT)
|
||||
-void ProcessingInstruction::setXSLStyleSheet(const String& url, const String& sheet)
|
||||
+void ProcessingInstruction::setXSLStyleSheet(const String& href, const KURL& baseURL, const String& sheet)
|
||||
{
|
||||
ASSERT(m_isXSL);
|
||||
- m_sheet = XSLStyleSheet::create(this, url);
|
||||
+ m_sheet = XSLStyleSheet::create(this, href, baseURL);
|
||||
parseStyleSheet(sheet);
|
||||
}
|
||||
#endif
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/ProcessingInstruction.h 2010-05-03 15:55:37.761977599 +0200
|
||||
@@ -68,9 +68,9 @@ private:
|
||||
virtual void removedFromDocument();
|
||||
|
||||
void checkStyleSheet();
|
||||
- virtual void setCSSStyleSheet(const String& url, const String& charset, const CachedCSSStyleSheet*);
|
||||
+ virtual void setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet*);
|
||||
#if ENABLE(XSLT)
|
||||
- virtual void setXSLStyleSheet(const String& url, const String& sheet);
|
||||
+ virtual void setXSLStyleSheet(const String& href, const KURL& baseURL, const String& sheet);
|
||||
#endif
|
||||
|
||||
bool isLoading() const;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/StyleElement.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/StyleElement.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/StyleElement.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/dom/StyleElement.cpp 2010-05-03 15:55:37.762976937 +0200
|
||||
@@ -103,7 +103,7 @@ void StyleElement::createSheet(Element*
|
||||
if (screenEval.eval(mediaList.get()) || printEval.eval(mediaList.get())) {
|
||||
document->addPendingSheet();
|
||||
setLoading(true);
|
||||
- m_sheet = CSSStyleSheet::create(e, String(), document->inputEncoding());
|
||||
+ m_sheet = CSSStyleSheet::create(e, String(), KURL(), document->inputEncoding());
|
||||
m_sheet->parseString(text, !document->inCompatMode());
|
||||
m_sheet->setMedia(mediaList.get());
|
||||
m_sheet->setTitle(e->title());
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.661976647 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.cpp 2010-05-03 17:02:45.528101154 +0200
|
||||
@@ -253,9 +253,9 @@ void HTMLLinkElement::finishParsingChild
|
||||
HTMLElement::finishParsingChildren();
|
||||
}
|
||||
|
||||
-void HTMLLinkElement::setCSSStyleSheet(const String& url, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
+void HTMLLinkElement::setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet* sheet)
|
||||
{
|
||||
- m_sheet = CSSStyleSheet::create(this, url, charset);
|
||||
+ m_sheet = CSSStyleSheet::create(this, href, baseURL, charset);
|
||||
|
||||
bool strictParsing = !document()->inCompatMode();
|
||||
bool enforceMIMEType = strictParsing;
|
||||
@@ -275,11 +275,11 @@ void HTMLLinkElement::setCSSStyleSheet(c
|
||||
// valid CSS rule.
|
||||
// This prevents an attacker playing games by injecting CSS strings into
|
||||
// HTML, XML, JSON, etc. etc.
|
||||
- if (!document()->securityOrigin()->canRequest(KURL(ParsedURLString, url)))
|
||||
+ if (!document()->securityOrigin()->canRequest(baseURL))
|
||||
crossOriginCSS = true;
|
||||
|
||||
if (crossOriginCSS && !validMIMEType && !m_sheet->hasSyntacticallyValidCSSHeader())
|
||||
- m_sheet = CSSStyleSheet::create(this, url, charset);
|
||||
+ m_sheet = CSSStyleSheet::create(this, href, baseURL, charset);
|
||||
|
||||
if (strictParsing && document()->settings() && document()->settings()->needsSiteSpecificQuirks()) {
|
||||
// Work around <https://bugs.webkit.org/show_bug.cgi?id=28350>.
|
||||
@@ -287,7 +287,7 @@ void HTMLLinkElement::setCSSStyleSheet(c
|
||||
DEFINE_STATIC_LOCAL(const String, mediaWikiKHTMLFixesStyleSheet, ("/* KHTML fix stylesheet */\n/* work around the horizontal scrollbars */\n#column-content { margin-left: 0; }\n\n"));
|
||||
// There are two variants of KHTMLFixes.css. One is equal to mediaWikiKHTMLFixesStyleSheet,
|
||||
// while the other lacks the second trailing newline.
|
||||
- if (url.endsWith(slashKHTMLFixesDotCss) && !sheetText.isNull() && mediaWikiKHTMLFixesStyleSheet.startsWith(sheetText)
|
||||
+ if (baseURL.string().endsWith(slashKHTMLFixesDotCss) && !sheetText.isNull() && mediaWikiKHTMLFixesStyleSheet.startsWith(sheetText)
|
||||
&& sheetText.length() >= mediaWikiKHTMLFixesStyleSheet.length() - 1) {
|
||||
ASSERT(m_sheet->length() == 1);
|
||||
ExceptionCode ec;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/html/HTMLLinkElement.h 2010-05-03 15:55:37.773083096 +0200
|
||||
@@ -79,7 +79,7 @@ public:
|
||||
virtual void removedFromDocument();
|
||||
|
||||
// from CachedResourceClient
|
||||
- virtual void setCSSStyleSheet(const String &url, const String& charset, const CachedCSSStyleSheet* sheet);
|
||||
+ virtual void setCSSStyleSheet(const String& href, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet* sheet);
|
||||
bool isLoading() const;
|
||||
virtual bool sheetLoaded();
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak 2010-05-03 15:55:37.661976647 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedCSSStyleSheet.cpp 2010-05-03 15:55:37.774976529 +0200
|
||||
@@ -52,9 +52,9 @@ CachedCSSStyleSheet::~CachedCSSStyleShee
|
||||
void CachedCSSStyleSheet::didAddClient(CachedResourceClient *c)
|
||||
{
|
||||
if (!m_loading)
|
||||
- c->setCSSStyleSheet(m_url, m_decoder->encoding().name(), this);
|
||||
+ c->setCSSStyleSheet(m_url, m_response.url(), m_decoder->encoding().name(), this);
|
||||
}
|
||||
-
|
||||
+
|
||||
void CachedCSSStyleSheet::allClientsRemoved()
|
||||
{
|
||||
if (isSafeToMakePurgeable())
|
||||
@@ -112,7 +112,7 @@ void CachedCSSStyleSheet::checkNotify()
|
||||
|
||||
CachedResourceClientWalker w(m_clients);
|
||||
while (CachedResourceClient *c = w.next())
|
||||
- c->setCSSStyleSheet(m_response.url().string(), m_decoder->encoding().name(), this);
|
||||
+ c->setCSSStyleSheet(m_url, m_response.url(), m_decoder->encoding().name(), this);
|
||||
}
|
||||
|
||||
void CachedCSSStyleSheet::error()
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedResourceClient.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedResourceClient.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedResourceClient.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedResourceClient.h 2010-05-03 15:55:37.775976911 +0200
|
||||
@@ -42,6 +42,7 @@ namespace WebCore {
|
||||
class String;
|
||||
class Image;
|
||||
class IntRect;
|
||||
+ class KURL;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
@@ -65,8 +66,8 @@ namespace WebCore {
|
||||
// e.g., in the b/f cache or in a background tab).
|
||||
virtual bool willRenderImage(CachedImage*) { return false; }
|
||||
|
||||
- virtual void setCSSStyleSheet(const String& /*URL*/, const String& /*charset*/, const CachedCSSStyleSheet*) { }
|
||||
- virtual void setXSLStyleSheet(const String& /*URL*/, const String& /*sheet*/) { }
|
||||
+ virtual void setCSSStyleSheet(const String& /* href */, const KURL& /* baseURL */, const String& /* charset */, const CachedCSSStyleSheet*) { }
|
||||
+ virtual void setXSLStyleSheet(const String& /* href */, const KURL& /* baseURL */, const String& /* sheet */) { }
|
||||
|
||||
virtual void fontLoaded(CachedFont*) {};
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedXSLStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedXSLStyleSheet.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedXSLStyleSheet.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:19.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/loader/CachedXSLStyleSheet.cpp 2010-05-03 15:55:37.789038977 +0200
|
||||
@@ -48,7 +48,7 @@ CachedXSLStyleSheet::CachedXSLStyleSheet
|
||||
void CachedXSLStyleSheet::didAddClient(CachedResourceClient* c)
|
||||
{
|
||||
if (!m_loading)
|
||||
- c->setXSLStyleSheet(m_url, m_sheet);
|
||||
+ c->setXSLStyleSheet(m_url, m_response.url(), m_sheet);
|
||||
}
|
||||
|
||||
void CachedXSLStyleSheet::setEncoding(const String& chs)
|
||||
@@ -83,10 +83,9 @@ void CachedXSLStyleSheet::checkNotify()
|
||||
|
||||
CachedResourceClientWalker w(m_clients);
|
||||
while (CachedResourceClient *c = w.next())
|
||||
- c->setXSLStyleSheet(m_url, m_sheet);
|
||||
+ c->setXSLStyleSheet(m_url, m_response.url(), m_sheet);
|
||||
}
|
||||
|
||||
-
|
||||
void CachedXSLStyleSheet::error()
|
||||
{
|
||||
m_loading = false;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.cpp 2010-05-03 15:55:37.789038977 +0200
|
||||
@@ -52,13 +52,13 @@ XSLStyleSheet* XSLImportRule::parentStyl
|
||||
return (parent() && parent()->isXSLStyleSheet()) ? static_cast<XSLStyleSheet*>(parent()) : 0;
|
||||
}
|
||||
|
||||
-void XSLImportRule::setXSLStyleSheet(const String& url, const String& sheet)
|
||||
+void XSLImportRule::setXSLStyleSheet(const String& href, const KURL& baseURL, const String& sheet)
|
||||
{
|
||||
if (m_styleSheet)
|
||||
m_styleSheet->setParent(0);
|
||||
-
|
||||
- m_styleSheet = XSLStyleSheet::create(this, url);
|
||||
-
|
||||
+
|
||||
+ m_styleSheet = XSLStyleSheet::create(this, href, baseURL);
|
||||
+
|
||||
XSLStyleSheet* parent = parentStyleSheet();
|
||||
if (parent)
|
||||
m_styleSheet->setParentStyleSheet(parent);
|
||||
@@ -87,14 +87,14 @@ void XSLImportRule::loadSheet()
|
||||
|
||||
String absHref = m_strHref;
|
||||
XSLStyleSheet* parentSheet = parentStyleSheet();
|
||||
- if (!parentSheet->href().isNull())
|
||||
+ if (!parentSheet->putativeBaseURL().isNull())
|
||||
// use parent styleheet's URL as the base URL
|
||||
- absHref = KURL(KURL(ParsedURLString, parentSheet->href()), m_strHref).string();
|
||||
+ absHref = KURL(parentSheet->putativeBaseURL(), m_strHref).string();
|
||||
|
||||
// Check for a cycle in our import chain. If we encounter a stylesheet
|
||||
// in our parent chain with the same URL, then just bail.
|
||||
for (parent = this->parent(); parent; parent = parent->parent()) {
|
||||
- if (parent->isXSLStyleSheet() && absHref == static_cast<XSLStyleSheet*>(parent)->href())
|
||||
+ if (parent->isXSLStyleSheet() && absHref == static_cast<XSLStyleSheet*>(parent)->putativeBaseURL().string())
|
||||
return;
|
||||
}
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLImportRule.h 2010-05-03 15:55:37.789981560 +0200
|
||||
@@ -57,7 +57,7 @@ private:
|
||||
virtual bool isImportRule() { return true; }
|
||||
|
||||
// from CachedResourceClient
|
||||
- virtual void setXSLStyleSheet(const String& url, const String& sheet);
|
||||
+ virtual void setXSLStyleSheet(const String& href, const KURL& baseURL, const String& sheet);
|
||||
|
||||
String m_strHref;
|
||||
RefPtr<XSLStyleSheet> m_styleSheet;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheet.h.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheet.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheet.h.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheet.h 2010-05-03 15:55:37.827976887 +0200
|
||||
@@ -43,18 +43,18 @@ class XSLImportRule;
|
||||
class XSLStyleSheet : public StyleSheet {
|
||||
public:
|
||||
#if !USE(QXMLQUERY)
|
||||
- static PassRefPtr<XSLStyleSheet> create(XSLImportRule* parentImport, const String& href)
|
||||
+ static PassRefPtr<XSLStyleSheet> create(XSLImportRule* parentImport, const String& href, const KURL& baseURL)
|
||||
{
|
||||
- return adoptRef(new XSLStyleSheet(parentImport, href));
|
||||
+ return adoptRef(new XSLStyleSheet(parentImport, href, baseURL));
|
||||
}
|
||||
#endif
|
||||
- static PassRefPtr<XSLStyleSheet> create(Node* parentNode, const String& href)
|
||||
+ static PassRefPtr<XSLStyleSheet> create(Node* parentNode, const String& href, const KURL& baseURL)
|
||||
{
|
||||
- return adoptRef(new XSLStyleSheet(parentNode, href, false));
|
||||
+ return adoptRef(new XSLStyleSheet(parentNode, href, baseURL, false));
|
||||
}
|
||||
- static PassRefPtr<XSLStyleSheet> createEmbedded(Node* parentNode, const String& href)
|
||||
+ static PassRefPtr<XSLStyleSheet> createEmbedded(Node* parentNode, const String& href, const KURL& baseURL)
|
||||
{
|
||||
- return adoptRef(new XSLStyleSheet(parentNode, href, true));
|
||||
+ return adoptRef(new XSLStyleSheet(parentNode, href, baseURL, true));
|
||||
}
|
||||
|
||||
virtual ~XSLStyleSheet();
|
||||
@@ -90,9 +90,9 @@ public:
|
||||
bool processed() const { return m_processed; }
|
||||
|
||||
private:
|
||||
- XSLStyleSheet(Node* parentNode, const String& href, bool embedded);
|
||||
+ XSLStyleSheet(Node* parentNode, const String& href, const KURL& baseURL, bool embedded);
|
||||
#if !USE(QXMLQUERY)
|
||||
- XSLStyleSheet(XSLImportRule* parentImport, const String& href);
|
||||
+ XSLStyleSheet(XSLImportRule* parentImport, const String& href, const KURL& baseURL);
|
||||
#endif
|
||||
|
||||
Document* m_ownerDocument;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetLibxslt.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetLibxslt.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetLibxslt.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetLibxslt.cpp 2010-05-03 15:55:37.837079694 +0200
|
||||
@@ -55,8 +55,8 @@ SOFT_LINK(libxslt, xsltLoadStylesheetPI,
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
-XSLStyleSheet::XSLStyleSheet(XSLImportRule* parentRule, const String& href)
|
||||
- : StyleSheet(parentRule, href)
|
||||
+XSLStyleSheet::XSLStyleSheet(XSLImportRule* parentRule, const String& href, const KURL& baseURL)
|
||||
+ : StyleSheet(parentRule, href, baseURL)
|
||||
, m_ownerDocument(0)
|
||||
, m_embedded(false)
|
||||
, m_processed(false) // Child sheets get marked as processed when the libxslt engine has finally seen them.
|
||||
@@ -66,8 +66,8 @@ XSLStyleSheet::XSLStyleSheet(XSLImportRu
|
||||
{
|
||||
}
|
||||
|
||||
-XSLStyleSheet::XSLStyleSheet(Node* parentNode, const String& href, bool embedded)
|
||||
- : StyleSheet(parentNode, href)
|
||||
+XSLStyleSheet::XSLStyleSheet(Node* parentNode, const String& href, const KURL& baseURL, bool embedded)
|
||||
+ : StyleSheet(parentNode, href, baseURL)
|
||||
, m_ownerDocument(parentNode->document())
|
||||
, m_embedded(embedded)
|
||||
, m_processed(true) // The root sheet starts off processed.
|
||||
@@ -168,7 +168,7 @@ bool XSLStyleSheet::parseString(const St
|
||||
}
|
||||
|
||||
m_stylesheetDoc = xmlCtxtReadMemory(ctxt, buffer, size,
|
||||
- href().utf8().data(),
|
||||
+ putativeBaseURL().string().utf8().data(),
|
||||
BOMHighByte == 0xFF ? "UTF-16LE" : "UTF-16BE",
|
||||
XML_PARSE_NOENT | XML_PARSE_DTDATTR | XML_PARSE_NOWARNING | XML_PARSE_NOCDATA);
|
||||
xmlFreeParserCtxt(ctxt);
|
||||
@@ -192,7 +192,7 @@ void XSLStyleSheet::loadChildSheets()
|
||||
if (m_embedded) {
|
||||
// We have to locate (by ID) the appropriate embedded stylesheet element, so that we can walk the
|
||||
// import/include list.
|
||||
- xmlAttrPtr idNode = xmlGetID(document(), (const xmlChar*)(href().utf8().data()));
|
||||
+ xmlAttrPtr idNode = xmlGetID(document(), (const xmlChar*)(putativeBaseURL().string().utf8().data()));
|
||||
if (!idNode)
|
||||
return;
|
||||
stylesheetRoot = idNode->parent;
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetQt.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetQt.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetQt.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLStyleSheetQt.cpp 2010-05-03 15:55:37.837977083 +0200
|
||||
@@ -33,8 +33,8 @@
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
-XSLStyleSheet::XSLStyleSheet(Node* parentNode, const String& href, bool embedded)
|
||||
- : StyleSheet(parentNode, href)
|
||||
+XSLStyleSheet::XSLStyleSheet(Node* parentNode, const String& href, const KURL& baseURL, bool embedded)
|
||||
+ : StyleSheet(parentNode, href, baseURL)
|
||||
, m_ownerDocument(parentNode->document())
|
||||
, m_embedded(embedded)
|
||||
{
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorLibxslt.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorLibxslt.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorLibxslt.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorLibxslt.cpp 2010-05-03 15:55:37.837977083 +0200
|
||||
@@ -226,7 +226,8 @@ static xsltStylesheetPtr xsltStylesheetP
|
||||
{
|
||||
if (!cachedStylesheet && stylesheetRootNode) {
|
||||
cachedStylesheet = XSLStyleSheet::create(stylesheetRootNode->parent() ? stylesheetRootNode->parent() : stylesheetRootNode,
|
||||
- stylesheetRootNode->document()->url().string());
|
||||
+ stylesheetRootNode->document()->url().string(),
|
||||
+ stylesheetRootNode->document()->url()); // FIXME: Should we use baseURL here?
|
||||
cachedStylesheet->parseString(createMarkup(stylesheetRootNode));
|
||||
}
|
||||
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorQt.cpp.cve-2010-0648-stylesheet-redir-leak qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorQt.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorQt.cpp.cve-2010-0648-stylesheet-redir-leak 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/xml/XSLTProcessorQt.cpp 2010-05-03 15:55:37.915979873 +0200
|
||||
@@ -120,7 +120,9 @@ bool XSLTProcessor::transformToString(No
|
||||
RefPtr<XSLStyleSheet> stylesheet = m_stylesheet;
|
||||
if (!stylesheet && m_stylesheetRootNode) {
|
||||
Node* node = m_stylesheetRootNode.get();
|
||||
- stylesheet = XSLStyleSheet::create(node->parent() ? node->parent() : node, node->document()->url().string());
|
||||
+ stylesheet = XSLStyleSheet::create(node->parent() ? node->parent() : node,
|
||||
+ node->document()->url().string(),
|
||||
+ node->document()->url()); // FIXME: Should we use baseURL here?
|
||||
stylesheet->parseString(createMarkup(node));
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/page/SecurityOrigin.cpp.me qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/page/SecurityOrigin.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/page/SecurityOrigin.cpp.me 2010-05-06 11:29:24.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/WebCore/page/SecurityOrigin.cpp 2010-05-06 11:43:29.000000000 +0200
|
||||
@@ -112,7 +112,11 @@ SecurityOrigin::SecurityOrigin(const KUR
|
||||
|
||||
// By default, only local SecurityOrigins can load local resources.
|
||||
m_canLoadLocalResources = isLocal();
|
||||
-
|
||||
+ if (m_canLoadLocalResources) {
|
||||
+ // Directories should never be readable.
|
||||
+ if (!url.hasPath() || url.path().endsWith("/"))
|
||||
+ m_noAccess = true;
|
||||
+ }
|
||||
if (isDefaultPortForProtocol(m_port, m_protocol))
|
||||
m_port = 0;
|
||||
}
|
||||
@@ -207,6 +211,8 @@ bool SecurityOrigin::canRequest(const KU
|
||||
return false;
|
||||
|
||||
RefPtr<SecurityOrigin> targetOrigin = SecurityOrigin::create(url);
|
||||
+ if (targetOrigin->m_noAccess)
|
||||
+ return false;
|
||||
|
||||
// We call isSameSchemeHostPort here instead of canAccess because we want
|
||||
// to ignore document.domain effects.
|
|
@ -0,0 +1,48 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h.than qt-everywhere-opensource-src-4.6.2/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h.than 2010-02-11 16:55:20.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/javascriptcore/JavaScriptCore/wtf/Platform.h 2010-03-23 14:29:41.000000000 +0100
|
||||
@@ -345,6 +345,11 @@
|
||||
#define WTF_PLATFORM_BIG_ENDIAN 1
|
||||
#endif
|
||||
|
||||
+/* PLATFORM(S390X) */
|
||||
+#if defined(__s390x__) || defined(__s390x)
|
||||
+#define WTF_PLATFORM_S390X 1
|
||||
+#endif
|
||||
+
|
||||
/* PLATFORM(IA64) */
|
||||
/* a.k.a. Itanium Processor Family, IPF */
|
||||
#if defined(__ia64) || defined(__ia64__) || defined(_M_IA64)
|
||||
@@ -730,6 +735,8 @@
|
||||
/* Using JSVALUE32_64 causes padding/alignement issues for JITStubArg
|
||||
on MinGW. See https://bugs.webkit.org/show_bug.cgi?id=29268 */
|
||||
#define WTF_USE_JSVALUE32 1
|
||||
+#elif PLATFORM(S390X)
|
||||
+#define WTF_USE_JSVALUE64 1
|
||||
#else
|
||||
#define WTF_USE_JSVALUE32_64 1
|
||||
#endif
|
||||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h.than qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h.than 2010-02-11 16:55:17.000000000 +0100
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h 2010-03-23 14:19:00.000000000 +0100
|
||||
@@ -362,6 +362,11 @@
|
||||
#define WTF_PLATFORM_IA64 1
|
||||
#endif
|
||||
|
||||
+/* PLATFORM(S390X) */
|
||||
+#if defined(__s390x__) || defined(__s390x)
|
||||
+#define WTF_PLATFORM_S390X 1
|
||||
+#endif
|
||||
+
|
||||
/* PLATFORM(ALPHA) */
|
||||
#if defined(__alpha__)
|
||||
#define WTF_PLATFORM_ALPHA 1
|
||||
@@ -729,7 +734,7 @@
|
||||
#endif
|
||||
|
||||
#if !defined(WTF_USE_JSVALUE64) && !defined(WTF_USE_JSVALUE32) && !defined(WTF_USE_JSVALUE32_64)
|
||||
-#if (PLATFORM(X86_64) && (PLATFORM(UNIX) || PLATFORM(WIN_OS))) || PLATFORM(IA64) || PLATFORM(ALPHA)
|
||||
+#if (PLATFORM(X86_64) && (PLATFORM(UNIX) || PLATFORM(WIN_OS))) || PLATFORM(IA64) || PLATFORM(ALPHA) || PLATFORM(S390X)
|
||||
#define WTF_USE_JSVALUE64 1
|
||||
#elif PLATFORM(ARM) || PLATFORM(PPC64)
|
||||
#define WTF_USE_JSVALUE32 1
|
|
@ -0,0 +1,16 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h.sparc qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h
|
||||
--- qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h.sparc 2010-03-23 10:45:57.076490991 -0400
|
||||
+++ qt-everywhere-opensource-src-4.6.2/src/3rdparty/webkit/JavaScriptCore/wtf/Platform.h 2010-03-23 10:47:37.044618125 -0400
|
||||
@@ -734,7 +734,11 @@
|
||||
#endif
|
||||
|
||||
#if !defined(WTF_USE_JSVALUE64) && !defined(WTF_USE_JSVALUE32) && !defined(WTF_USE_JSVALUE32_64)
|
||||
-#if (PLATFORM(X86_64) && (PLATFORM(UNIX) || PLATFORM(WIN_OS))) || PLATFORM(IA64) || PLATFORM(ALPHA) || PLATFORM(S390X)
|
||||
+#if (PLATFORM(X86_64) && (PLATFORM(UNIX) || PLATFORM(WIN_OS))) \
|
||||
+ || PLATFORM(IA64) \
|
||||
+ || PLATFORM(ALPHA) \
|
||||
+ || PLATFORM(SPARC64) \
|
||||
+ || PLATFORM(S390X)
|
||||
#define WTF_USE_JSVALUE64 1
|
||||
#elif PLATFORM(ARM) || PLATFORM(PPC64)
|
||||
#define WTF_USE_JSVALUE32 1
|
|
@ -0,0 +1,15 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Node.cpp.CVE-2010-1119 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Node.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Node.cpp.CVE-2010-1119 2010-06-02 04:03:12.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Node.cpp 2010-06-15 13:11:55.974470742 +0200
|
||||
@@ -910,7 +910,10 @@ void Node::notifyLocalNodeListsAttribute
|
||||
if (!data->nodeLists())
|
||||
return;
|
||||
|
||||
- data->nodeLists()->invalidateCachesThatDependOnAttributes();
|
||||
+ if (!isAttributeNode())
|
||||
+ data->nodeLists()->invalidateCachesThatDependOnAttributes();
|
||||
+ else
|
||||
+ data->nodeLists()->invalidateCaches();
|
||||
|
||||
if (data->nodeLists()->isEmpty()) {
|
||||
data->clearNodeLists();
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,12 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderBlock.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1392/src/3rdparty/webkit/WebCore/rendering/RenderBlock.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderBlock.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1392/src/3rdparty/webkit/WebCore/rendering/RenderBlock.cpp 2010-06-10 20:24:02.864193022 +0200
|
||||
@@ -4484,7 +4484,7 @@
|
||||
|
||||
// Drill into inlines looking for our first text child.
|
||||
RenderObject* currChild = firstLetterBlock->firstChild();
|
||||
- while (currChild && currChild->needsLayout() && (!currChild->isReplaced() || currChild->isFloatingOrPositioned()) && !currChild->isText()) {
|
||||
+ while (currChild && currChild->needsLayout() && ((!currChild->isReplaced() && !currChild->isRenderButton() && !currChild->isMenuList()) || currChild->isFloatingOrPositioned()) && !currChild->isText()) {
|
||||
if (currChild->isFloatingOrPositioned()) {
|
||||
if (currChild->style()->styleType() == FIRST_LETTER)
|
||||
break;
|
|
@ -0,0 +1,56 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/ContainerNode.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1396/src/3rdparty/webkit/WebCore/dom/ContainerNode.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/ContainerNode.cpp 2010-06-02 04:03:12.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1396/src/3rdparty/webkit/WebCore/dom/ContainerNode.cpp 2010-06-10 20:34:00.316318866 +0200
|
||||
@@ -395,33 +395,43 @@
|
||||
document()->removeFocusedNodeOfSubtree(this, true);
|
||||
|
||||
forbidEventDispatch();
|
||||
- int childCountDelta = 0;
|
||||
+ Vector<RefPtr<Node> > removedChildren;
|
||||
while (RefPtr<Node> n = m_firstChild) {
|
||||
- childCountDelta--;
|
||||
-
|
||||
Node* next = n->nextSibling();
|
||||
|
||||
- // Remove the node from the tree before calling detach or removedFromDocument (4427024, 4129744)
|
||||
+ // Remove the node from the tree before calling detach or removedFromDocument (4427024, 4129744).
|
||||
+ // removeChild() does this after calling detach(). There is no explanation for
|
||||
+ // this discrepancy between removeChild() and its optimized version removeChildren().
|
||||
n->setPreviousSibling(0);
|
||||
n->setNextSibling(0);
|
||||
n->setParent(0);
|
||||
-
|
||||
+
|
||||
m_firstChild = next;
|
||||
if (n == m_lastChild)
|
||||
m_lastChild = 0;
|
||||
|
||||
if (n->attached())
|
||||
n->detach();
|
||||
-
|
||||
- if (n->inDocument())
|
||||
- n->removedFromDocument();
|
||||
+
|
||||
+ removedChildren.append(n.release());
|
||||
}
|
||||
allowEventDispatch();
|
||||
|
||||
+ size_t removedChildrenCount = removedChildren.size();
|
||||
+
|
||||
// Dispatch a single post-removal mutation event denoting a modified subtree.
|
||||
- childrenChanged(false, 0, 0, childCountDelta);
|
||||
+ childrenChanged(false, 0, 0, -static_cast<int>(removedChildrenCount));
|
||||
dispatchSubtreeModifiedEvent();
|
||||
|
||||
+ for (size_t i = 0; i < removedChildrenCount; ++i) {
|
||||
+ Node* removedChild = removedChildren[i].get();
|
||||
+ if (removedChild->inDocument())
|
||||
+ removedChild->removedFromDocument();
|
||||
+ // removeChild() calls removedFromTree(true) if the child was not in the
|
||||
+ // document. There is no explanation for this discrepancy between removeChild()
|
||||
+ // and its optimized version removeChildren().
|
||||
+ }
|
||||
+
|
||||
return true;
|
||||
}
|
||||
|
|
@ -0,0 +1,53 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/Frame.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/Frame.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/Frame.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/Frame.cpp 2010-06-10 20:41:45.295318418 +0200
|
||||
@@ -552,12 +552,6 @@
|
||||
toRenderTextControl(renderer)->selectionChanged(userTriggered);
|
||||
}
|
||||
|
||||
-void Frame::invalidateSelection()
|
||||
-{
|
||||
- selection()->setNeedsLayout();
|
||||
- selectionLayoutChanged();
|
||||
-}
|
||||
-
|
||||
void Frame::setCaretVisible(bool flag)
|
||||
{
|
||||
if (m_caretVisible == flag)
|
||||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/Frame.h qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/Frame.h
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/Frame.h 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/Frame.h 2010-06-10 20:41:45.291318453 +0200
|
||||
@@ -259,8 +259,6 @@
|
||||
void selectionLayoutChanged();
|
||||
void notifyRendererOfSelectionChange(bool userTriggered);
|
||||
|
||||
- void invalidateSelection();
|
||||
-
|
||||
void setCaretVisible(bool = true);
|
||||
void paintCaret(GraphicsContext*, int tx, int ty, const IntRect& clipRect) const;
|
||||
void paintDragCaret(GraphicsContext*, int tx, int ty, const IntRect& clipRect) const;
|
||||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/FrameView.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/page/FrameView.cpp 2010-06-10 20:41:45.293318191 +0200
|
||||
@@ -642,7 +642,8 @@
|
||||
root->view()->popLayoutState();
|
||||
m_layoutRoot = 0;
|
||||
|
||||
- m_frame->invalidateSelection();
|
||||
+ m_frame->selection()->setNeedsLayout();
|
||||
+ m_frame->selectionLayoutChanged();
|
||||
|
||||
m_layoutSchedulingEnabled = true;
|
||||
|
||||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1397/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp 2010-06-10 20:41:45.297318506 +0200
|
||||
@@ -1170,7 +1170,7 @@
|
||||
// The caret rect needs to be invalidated after scrolling
|
||||
Frame* frame = renderer()->document()->frame();
|
||||
if (frame)
|
||||
- frame->invalidateSelection();
|
||||
+ frame->selection()->setNeedsLayout();
|
||||
|
||||
// Just schedule a full repaint of our object.
|
||||
if (repaint)
|
|
@ -0,0 +1,244 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.cpp.CVE-2010-1398 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.cpp.CVE-2010-1398 2010-06-02 04:03:12.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.cpp 2010-06-11 16:12:55.750525354 +0200
|
||||
@@ -35,6 +35,7 @@
|
||||
#include "ClientRect.h"
|
||||
#include "ClientRectList.h"
|
||||
#include "Document.h"
|
||||
+#include "DocumentFragment.h"
|
||||
#include "ElementRareData.h"
|
||||
#include "ExceptionCode.h"
|
||||
#include "FocusController.h"
|
||||
@@ -42,6 +43,7 @@
|
||||
#include "FrameView.h"
|
||||
#include "HTMLElement.h"
|
||||
#include "HTMLNames.h"
|
||||
+#include "HTMLTokenizer.h"
|
||||
#include "NamedNodeMap.h"
|
||||
#include "NodeList.h"
|
||||
#include "NodeRenderStyle.h"
|
||||
@@ -49,6 +51,7 @@
|
||||
#include "RenderView.h"
|
||||
#include "TextIterator.h"
|
||||
#include "XMLNames.h"
|
||||
+#include "XMLTokenizer.h"
|
||||
|
||||
#if ENABLE(SVG)
|
||||
#include "SVGNames.h"
|
||||
@@ -91,6 +94,51 @@ NodeRareData* Element::createRareData()
|
||||
{
|
||||
return new ElementRareData;
|
||||
}
|
||||
+
|
||||
+PassRefPtr<DocumentFragment> Element::createContextualFragment(const String& markup)
|
||||
+{
|
||||
+ RefPtr<DocumentFragment> fragment = DocumentFragment::create(document());
|
||||
+
|
||||
+ if (document()->isHTMLDocument())
|
||||
+ parseHTMLDocumentFragment(markup, fragment.get());
|
||||
+ else {
|
||||
+ if (!parseXMLDocumentFragment(markup, fragment.get(), this))
|
||||
+ // FIXME: We should propagate a syntax error exception out here.
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ // Exceptions are ignored because none ought to happen here.
|
||||
+ ExceptionCode ignoredExceptionCode;
|
||||
+
|
||||
+ // We need to pop <html> and <body> elements and remove <head> to
|
||||
+ // accommodate folks passing complete HTML documents to make the
|
||||
+ // child of an element.
|
||||
+
|
||||
+ RefPtr<Node> nextNode;
|
||||
+ for (RefPtr<Node> node = fragment->firstChild(); node; node = nextNode) {
|
||||
+ nextNode = node->nextSibling();
|
||||
+ if (node->hasTagName(htmlTag) || node->hasTagName(bodyTag)) {
|
||||
+ Node* firstChild = node->firstChild();
|
||||
+ if (firstChild)
|
||||
+ nextNode = firstChild;
|
||||
+ RefPtr<Node> nextChild;
|
||||
+ for (RefPtr<Node> child = firstChild; child; child = nextChild) {
|
||||
+ nextChild = child->nextSibling();
|
||||
+ node->removeChild(child.get(), ignoredExceptionCode);
|
||||
+ ASSERT(!ignoredExceptionCode);
|
||||
+ fragment->insertBefore(child, node.get(), ignoredExceptionCode);
|
||||
+ ASSERT(!ignoredExceptionCode);
|
||||
+ }
|
||||
+ fragment->removeChild(node.get(), ignoredExceptionCode);
|
||||
+ ASSERT(!ignoredExceptionCode);
|
||||
+ } else if (node->hasTagName(headTag)) {
|
||||
+ fragment->removeChild(node.get(), ignoredExceptionCode);
|
||||
+ ASSERT(!ignoredExceptionCode);
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return fragment.release();
|
||||
+}
|
||||
|
||||
PassRefPtr<Node> Element::cloneNode(bool deep)
|
||||
{
|
||||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.h.CVE-2010-1398 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.h
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.h.CVE-2010-1398 2010-06-02 04:03:12.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/dom/Element.h 2010-06-14 16:54:57.639394749 +0200
|
||||
@@ -28,6 +28,7 @@
|
||||
#include "ContainerNode.h"
|
||||
#include "QualifiedName.h"
|
||||
#include "ScrollTypes.h"
|
||||
+#include "DocumentFragment.h"
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
@@ -89,6 +90,8 @@ public:
|
||||
DEFINE_ATTRIBUTE_EVENT_LISTENER(search);
|
||||
DEFINE_ATTRIBUTE_EVENT_LISTENER(selectstart);
|
||||
|
||||
+ virtual PassRefPtr<DocumentFragment> createContextualFragment(const String&);
|
||||
+
|
||||
const AtomicString& getIDAttribute() const;
|
||||
bool hasAttribute(const QualifiedName&) const;
|
||||
const AtomicString& getAttribute(const QualifiedName&) const;
|
||||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/editing/markup.cpp.CVE-2010-1398 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/editing/markup.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/editing/markup.cpp.CVE-2010-1398 2010-06-02 04:03:10.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/editing/markup.cpp 2010-06-11 16:12:55.752525451 +0200
|
||||
@@ -1054,11 +1054,7 @@ String createMarkup(const Range* range,
|
||||
|
||||
PassRefPtr<DocumentFragment> createFragmentFromMarkup(Document* document, const String& markup, const String& baseURL)
|
||||
{
|
||||
- ASSERT(document->documentElement()->isHTMLElement());
|
||||
- // FIXME: What if the document element is not an HTML element?
|
||||
- HTMLElement *element = static_cast<HTMLElement*>(document->documentElement());
|
||||
-
|
||||
- RefPtr<DocumentFragment> fragment = element->createContextualFragment(markup);
|
||||
+ RefPtr<DocumentFragment> fragment = document->documentElement()->createContextualFragment(markup);
|
||||
|
||||
if (fragment && !baseURL.isEmpty() && baseURL != blankURL() && baseURL != document->baseURL())
|
||||
completeURLs(fragment.get(), baseURL);
|
||||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/html/HTMLElement.cpp.CVE-2010-1398 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/html/HTMLElement.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/html/HTMLElement.cpp.CVE-2010-1398 2010-06-02 04:03:10.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/html/HTMLElement.cpp 2010-06-11 16:12:55.753537613 +0200
|
||||
@@ -235,9 +235,9 @@ String HTMLElement::outerHTML() const
|
||||
return createMarkup(this);
|
||||
}
|
||||
|
||||
-PassRefPtr<DocumentFragment> HTMLElement::createContextualFragment(const String &html)
|
||||
+PassRefPtr<DocumentFragment> HTMLElement::createContextualFragment(const String &markup)
|
||||
{
|
||||
- // the following is in accordance with the definition as used by IE
|
||||
+ // The following is in accordance with the definition as used by IE.
|
||||
if (endTagRequirement() == TagStatusForbidden)
|
||||
return 0;
|
||||
|
||||
@@ -245,47 +245,7 @@ PassRefPtr<DocumentFragment> HTMLElement
|
||||
hasLocalName(headTag) || hasLocalName(styleTag) || hasLocalName(titleTag))
|
||||
return 0;
|
||||
|
||||
- RefPtr<DocumentFragment> fragment = DocumentFragment::create(document());
|
||||
-
|
||||
- if (document()->isHTMLDocument())
|
||||
- parseHTMLDocumentFragment(html, fragment.get());
|
||||
- else {
|
||||
- if (!parseXMLDocumentFragment(html, fragment.get(), this))
|
||||
- // FIXME: We should propagate a syntax error exception out here.
|
||||
- return 0;
|
||||
- }
|
||||
-
|
||||
- // Exceptions are ignored because none ought to happen here.
|
||||
- int ignoredExceptionCode;
|
||||
-
|
||||
- // we need to pop <html> and <body> elements and remove <head> to
|
||||
- // accommodate folks passing complete HTML documents to make the
|
||||
- // child of an element.
|
||||
-
|
||||
- RefPtr<Node> nextNode;
|
||||
- for (RefPtr<Node> node = fragment->firstChild(); node; node = nextNode) {
|
||||
- nextNode = node->nextSibling();
|
||||
- if (node->hasTagName(htmlTag) || node->hasTagName(bodyTag)) {
|
||||
- Node *firstChild = node->firstChild();
|
||||
- if (firstChild)
|
||||
- nextNode = firstChild;
|
||||
- RefPtr<Node> nextChild;
|
||||
- for (RefPtr<Node> child = firstChild; child; child = nextChild) {
|
||||
- nextChild = child->nextSibling();
|
||||
- node->removeChild(child.get(), ignoredExceptionCode);
|
||||
- ASSERT(!ignoredExceptionCode);
|
||||
- fragment->insertBefore(child, node.get(), ignoredExceptionCode);
|
||||
- ASSERT(!ignoredExceptionCode);
|
||||
- }
|
||||
- fragment->removeChild(node.get(), ignoredExceptionCode);
|
||||
- ASSERT(!ignoredExceptionCode);
|
||||
- } else if (node->hasTagName(headTag)) {
|
||||
- fragment->removeChild(node.get(), ignoredExceptionCode);
|
||||
- ASSERT(!ignoredExceptionCode);
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- return fragment.release();
|
||||
+ return Element::createContextualFragment(markup);
|
||||
}
|
||||
|
||||
static inline bool hasOneChild(ContainerNode* node)
|
||||
@@ -371,7 +331,7 @@ void HTMLElement::setOuterHTML(const Str
|
||||
|
||||
void HTMLElement::setInnerText(const String& text, ExceptionCode& ec)
|
||||
{
|
||||
- // follow the IE specs about when this is allowed
|
||||
+ // Follow the IE specs about when this is allowed.
|
||||
if (endTagRequirement() == TagStatusForbidden) {
|
||||
ec = NO_MODIFICATION_ALLOWED_ERR;
|
||||
return;
|
||||
@@ -441,7 +401,7 @@ void HTMLElement::setInnerText(const Str
|
||||
|
||||
void HTMLElement::setOuterText(const String &text, ExceptionCode& ec)
|
||||
{
|
||||
- // follow the IE specs about when this is allowed
|
||||
+ // Follow the IE specs about when this is allowed.
|
||||
if (endTagRequirement() == TagStatusForbidden) {
|
||||
ec = NO_MODIFICATION_ALLOWED_ERR;
|
||||
return;
|
||||
@@ -469,7 +429,7 @@ void HTMLElement::setOuterText(const Str
|
||||
if (ec)
|
||||
return;
|
||||
|
||||
- // is previous node a text node? if so, merge into it
|
||||
+ // Is previous node a text node? If so, merge into it.
|
||||
Node* prev = t->previousSibling();
|
||||
if (prev && prev->isTextNode()) {
|
||||
Text* textPrev = static_cast<Text*>(prev);
|
||||
@@ -482,7 +442,7 @@ void HTMLElement::setOuterText(const Str
|
||||
t = textPrev;
|
||||
}
|
||||
|
||||
- // is next node a text node? if so, merge it in
|
||||
+ // Is next node a text node? If so, merge it in.
|
||||
Node* next = t->nextSibling();
|
||||
if (next && next->isTextNode()) {
|
||||
Text* textNext = static_cast<Text*>(next);
|
||||
@@ -522,7 +482,7 @@ Node* HTMLElement::insertAdjacent(const
|
||||
return 0;
|
||||
}
|
||||
|
||||
- // IE throws COM Exception E_INVALIDARG; this is the best DOM exception alternative
|
||||
+ // IE throws COM Exception E_INVALIDARG; this is the best DOM exception alternative.
|
||||
ec = NOT_SUPPORTED_ERR;
|
||||
return 0;
|
||||
}
|
||||
@@ -530,7 +490,7 @@ Node* HTMLElement::insertAdjacent(const
|
||||
Element* HTMLElement::insertAdjacentElement(const String& where, Element* newChild, ExceptionCode& ec)
|
||||
{
|
||||
if (!newChild) {
|
||||
- // IE throws COM Exception E_INVALIDARG; this is the best DOM exception alternative
|
||||
+ // IE throws COM Exception E_INVALIDARG; this is the best DOM exception alternative.
|
||||
ec = TYPE_MISMATCH_ERR;
|
||||
return 0;
|
||||
}
|
||||
@@ -567,8 +527,8 @@ void HTMLElement::addHTMLAlignment(Mappe
|
||||
|
||||
void HTMLElement::addHTMLAlignmentToStyledElement(StyledElement* element, MappedAttribute* attr)
|
||||
{
|
||||
- // vertical alignment with respect to the current baseline of the text
|
||||
- // right or left means floating images
|
||||
+ // Vertical alignment with respect to the current baseline of the text
|
||||
+ // right or left means floating images.
|
||||
int floatValue = CSSValueInvalid;
|
||||
int verticalAlignValue = CSSValueInvalid;
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderObject.cpp.CVE-2010-1400 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderObject.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderObject.cpp.CVE-2010-1400 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderObject.cpp 2010-06-15 13:55:36.853463455 +0200
|
||||
@@ -1611,7 +1611,7 @@ void RenderObject::styleWillChange(Style
|
||||
}
|
||||
}
|
||||
|
||||
-void RenderObject::styleDidChange(StyleDifference diff, const RenderStyle*)
|
||||
+void RenderObject::styleDidChange(StyleDifference diff, const RenderStyle* oldStyle)
|
||||
{
|
||||
if (s_affectsParentBlock)
|
||||
handleDynamicFloatPositionChange();
|
||||
@@ -1619,9 +1619,17 @@ void RenderObject::styleDidChange(StyleD
|
||||
if (!m_parent)
|
||||
return;
|
||||
|
||||
- if (diff == StyleDifferenceLayout)
|
||||
+ if (diff == StyleDifferenceLayout) {
|
||||
+ // If the object already needs layout, then setNeedsLayout won't do
|
||||
+ // any work. But if the containing block has changed, then we may need
|
||||
+ // to make the new containing blocks for layout. The change that can
|
||||
+ // directly affect the containing block of this object is a change to
|
||||
+ // the position style.
|
||||
+ if (m_needsLayout && oldStyle->position() != m_style->position())
|
||||
+ markContainingBlocksForLayout();
|
||||
+
|
||||
setNeedsLayoutAndPrefWidthsRecalc();
|
||||
- else if (diff == StyleDifferenceLayoutPositionedMovementOnly)
|
||||
+ } else if (diff == StyleDifferenceLayoutPositionedMovementOnly)
|
||||
setNeedsPositionedMovementLayout();
|
||||
|
||||
// Don't check for repaint here; we need to wait until the layer has been
|
|
@ -0,0 +1,45 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp qt-everywhere-opensource-src-4.6.3-2010-1412/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-2010-1412/src/3rdparty/webkit/WebCore/rendering/RenderLayer.cpp 2010-06-11 00:09:43.741191104 +0200
|
||||
@@ -3039,22 +3039,33 @@
|
||||
// Locate the common ancestor render object for the two renderers.
|
||||
RenderObject* ancestor = commonAncestor(oldHoverObj, newHoverObj);
|
||||
|
||||
+ Vector<Node*, 32> nodesToRemoveFromChain;
|
||||
+ Vector<Node*, 32> nodesToAddToChain;
|
||||
+
|
||||
if (oldHoverObj != newHoverObj) {
|
||||
// The old hover path only needs to be cleared up to (and not including) the common ancestor;
|
||||
for (RenderObject* curr = oldHoverObj; curr && curr != ancestor; curr = curr->hoverAncestor()) {
|
||||
- if (curr->node() && !curr->isText() && (!mustBeInActiveChain || curr->node()->inActiveChain())) {
|
||||
- curr->node()->setActive(false);
|
||||
- curr->node()->setHovered(false);
|
||||
- }
|
||||
+ if (curr->node() && !curr->isText() && (!mustBeInActiveChain || curr->node()->inActiveChain()))
|
||||
+ nodesToRemoveFromChain.append(curr->node());
|
||||
}
|
||||
}
|
||||
|
||||
// Now set the hover state for our new object up to the root.
|
||||
for (RenderObject* curr = newHoverObj; curr; curr = curr->hoverAncestor()) {
|
||||
- if (curr->node() && !curr->isText() && (!mustBeInActiveChain || curr->node()->inActiveChain())) {
|
||||
- curr->node()->setActive(request.active());
|
||||
- curr->node()->setHovered(true);
|
||||
- }
|
||||
+ if (curr->node() && !curr->isText() && (!mustBeInActiveChain || curr->node()->inActiveChain()))
|
||||
+ nodesToAddToChain.append(curr->node());
|
||||
+ }
|
||||
+
|
||||
+ size_t removeCount = nodesToRemoveFromChain.size();
|
||||
+ for (size_t i = 0; i < removeCount; ++i) {
|
||||
+ nodesToRemoveFromChain[i]->setActive(false);
|
||||
+ nodesToRemoveFromChain[i]->setHovered(false);
|
||||
+ }
|
||||
+
|
||||
+ size_t addCount = nodesToAddToChain.size();
|
||||
+ for (size_t i = 0; i < addCount; ++i) {
|
||||
+ nodesToAddToChain[i]->setActive(request.active());
|
||||
+ nodesToAddToChain[i]->setHovered(true);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,33 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderText.cpp qt-everywhere-opensource-src-4.6.3-CVE-1770/src/3rdparty/webkit/WebCore/rendering/RenderText.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderText.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-1770/src/3rdparty/webkit/WebCore/rendering/RenderText.cpp 2010-06-11 13:42:31.190174662 +0200
|
||||
@@ -207,7 +207,7 @@
|
||||
PassRefPtr<StringImpl> RenderText::originalText() const
|
||||
{
|
||||
Node* e = node();
|
||||
- return e ? static_cast<Text*>(e)->dataImpl() : 0;
|
||||
+ return (e && e->isTextNode()) ? static_cast<Text*>(e)->dataImpl() : 0;
|
||||
}
|
||||
|
||||
void RenderText::absoluteRects(Vector<IntRect>& rects, int tx, int ty)
|
||||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderTextFragment.cpp qt-everywhere-opensource-src-4.6.3-CVE-1770/src/3rdparty/webkit/WebCore/rendering/RenderTextFragment.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderTextFragment.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-1770/src/3rdparty/webkit/WebCore/rendering/RenderTextFragment.cpp 2010-06-11 13:42:31.197153658 +0200
|
||||
@@ -47,7 +47,7 @@
|
||||
PassRefPtr<StringImpl> RenderTextFragment::originalText() const
|
||||
{
|
||||
Node* e = node();
|
||||
- RefPtr<StringImpl> result = (e ? static_cast<Text*>(e)->dataImpl() : contentString());
|
||||
+ RefPtr<StringImpl> result = ((e && e->isTextNode()) ? static_cast<Text*>(e)->dataImpl() : contentString());
|
||||
if (result && (start() > 0 || start() < result->length()))
|
||||
result = result->substring(start(), end());
|
||||
return result.release();
|
||||
@@ -76,7 +76,7 @@
|
||||
{
|
||||
if (start()) {
|
||||
Node* e = node();
|
||||
- StringImpl* original = (e ? static_cast<Text*>(e)->dataImpl() : contentString());
|
||||
+ StringImpl* original = ((e && e->isTextNode()) ? static_cast<Text*>(e)->dataImpl() : contentString());
|
||||
if (original)
|
||||
return (*original)[start() - 1];
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderListMarker.cpp qt-everywhere-opensource-src-4.6.3-CVE-2010-1773/src/3rdparty/webkit/WebCore/rendering/RenderListMarker.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/RenderListMarker.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-2010-1773/src/3rdparty/webkit/WebCore/rendering/RenderListMarker.cpp 2010-06-10 17:33:06.092192665 +0200
|
||||
@@ -88,8 +88,10 @@
|
||||
--number;
|
||||
letters[lettersSize - 1] = alphabet[number % alphabetSize];
|
||||
int length = 1;
|
||||
- while ((number /= alphabetSize) > 0)
|
||||
- letters[lettersSize - ++length] = alphabet[number % alphabetSize - 1];
|
||||
+ while ((number /= alphabetSize) > 0) {
|
||||
+ --number;
|
||||
+ letters[lettersSize - ++length] = alphabet[number % alphabetSize];
|
||||
+ }
|
||||
|
||||
ASSERT(length <= lettersSize);
|
||||
return String(&letters[lettersSize - length], length);
|
|
@ -0,0 +1,13 @@
|
|||
diff -ur qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/FixedTableLayout.cpp qt-everywhere-opensource-src-4.6.3-CVE-1774/src/3rdparty/webkit/WebCore/rendering/FixedTableLayout.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/rendering/FixedTableLayout.cpp 2010-06-02 04:03:11.000000000 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3-CVE-1774/src/3rdparty/webkit/WebCore/rendering/FixedTableLayout.cpp 2010-06-11 14:45:02.625278334 +0200
|
||||
@@ -168,8 +168,7 @@
|
||||
|
||||
int usedSpan = 0;
|
||||
int i = 0;
|
||||
- while (usedSpan < span) {
|
||||
- ASSERT(cCol + i < nEffCols);
|
||||
+ while (usedSpan < span && cCol + i < nEffCols) {
|
||||
int eSpan = m_table->spanOfEffCol(cCol + i);
|
||||
// Only set if no col element has already set it.
|
||||
if (m_width[cCol + i].isAuto() && w.type() != Auto) {
|
|
@ -0,0 +1,29 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp.CVE-2010-1778 qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp.CVE-2010-1778 2010-06-11 16:12:55.786338275 +0200
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/3rdparty/webkit/WebCore/page/FrameView.cpp 2010-06-15 13:23:21.114401487 +0200
|
||||
@@ -1189,14 +1189,13 @@ void FrameView::scheduleRelayoutOfSubtre
|
||||
{
|
||||
ASSERT(m_frame->view() == this);
|
||||
|
||||
- if (!m_layoutSchedulingEnabled || (m_frame->contentRenderer()
|
||||
- && m_frame->contentRenderer()->needsLayout())) {
|
||||
+ if (m_frame->contentRenderer() && m_frame->contentRenderer()->needsLayout()) {
|
||||
if (relayoutRoot)
|
||||
relayoutRoot->markContainingBlocksForLayout(false);
|
||||
return;
|
||||
}
|
||||
|
||||
- if (layoutPending()) {
|
||||
+ if (layoutPending() || !m_layoutSchedulingEnabled) {
|
||||
if (m_layoutRoot != relayoutRoot) {
|
||||
if (isObjectAncestorContainerOf(m_layoutRoot, relayoutRoot)) {
|
||||
// Keep the current root
|
||||
@@ -1213,7 +1212,7 @@ void FrameView::scheduleRelayoutOfSubtre
|
||||
relayoutRoot->markContainingBlocksForLayout(false);
|
||||
}
|
||||
}
|
||||
- } else {
|
||||
+ } else if (m_layoutSchedulingEnabled) {
|
||||
int delay = m_frame->document()->minimumLayoutDelay();
|
||||
m_layoutRoot = relayoutRoot;
|
||||
m_delayedLayout = delay != 0;
|
|
@ -0,0 +1,21 @@
|
|||
diff -up qt-everywhere-opensource-src-4.6.3/src/gui/kernel/qguieventdispatcher_glib.cpp.glib_eventloop_nullcheck qt-everywhere-opensource-src-4.6.3/src/gui/kernel/qguieventdispatcher_glib.cpp
|
||||
--- qt-everywhere-opensource-src-4.6.3/src/gui/kernel/qguieventdispatcher_glib.cpp.glib_eventloop_nullcheck 2010-06-01 21:03:15.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.6.3/src/gui/kernel/qguieventdispatcher_glib.cpp 2010-06-29 14:58:12.299073784 -0500
|
||||
@@ -76,7 +76,7 @@ static gboolean x11EventSourcePrepare(GS
|
||||
GX11EventSource *source = reinterpret_cast<GX11EventSource *>(s);
|
||||
return (XEventsQueued(X11->display, QueuedAfterFlush)
|
||||
|| (!(source->flags & QEventLoop::ExcludeUserInputEvents)
|
||||
- && !source->d->queuedUserInputEvents.isEmpty()));
|
||||
+ && source->d && !source->d->queuedUserInputEvents.isEmpty()));
|
||||
}
|
||||
|
||||
static gboolean x11EventSourceCheck(GSource *s)
|
||||
@@ -84,7 +84,7 @@ static gboolean x11EventSourceCheck(GSou
|
||||
GX11EventSource *source = reinterpret_cast<GX11EventSource *>(s);
|
||||
return (XEventsQueued(X11->display, QueuedAfterFlush)
|
||||
|| (!(source->flags & QEventLoop::ExcludeUserInputEvents)
|
||||
- && !source->d->queuedUserInputEvents.isEmpty()));
|
||||
+ && source->d && !source->d->queuedUserInputEvents.isEmpty()));
|
||||
}
|
||||
|
||||
static gboolean x11EventSourceDispatch(GSource *s, GSourceFunc callback, gpointer user_data)
|
|
@ -0,0 +1,34 @@
|
|||
From 9e9a7bc29319d52c3e563bc2c5282cb7e6890eba Mon Sep 17 00:00:00 2001
|
||||
From: Denis Dzyubenko <denis.dzyubenko@nokia.com>
|
||||
Date: Wed, 29 Sep 2010 14:02:10 +0200
|
||||
Subject: [PATCH] Fixes cursor shape when widget becomes native on X11.
|
||||
|
||||
When a native window handle is created for a widget that has override
|
||||
cursor set, we should reset the cursor on the parent and set the cursor
|
||||
on the new window handle.
|
||||
|
||||
Task-number: QTBUG-6185
|
||||
Reviewed-by: Olivier Goffart
|
||||
---
|
||||
src/gui/kernel/qwidget_x11.cpp | 4 +++-
|
||||
1 files changed, 3 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qwidget_x11.cpp b/src/gui/kernel/qwidget_x11.cpp
|
||||
index e01489f..8d80e10 100644
|
||||
--- a/src/gui/kernel/qwidget_x11.cpp
|
||||
+++ b/src/gui/kernel/qwidget_x11.cpp
|
||||
@@ -889,8 +889,10 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
|
||||
q->setWindowOpacity(maybeTopData()->opacity/255.);
|
||||
|
||||
}
|
||||
- } else if (q->testAttribute(Qt::WA_SetCursor) && q->internalWinId()) {
|
||||
+ } else if (q->internalWinId()) {
|
||||
qt_x11_enforce_cursor(q);
|
||||
+ if (QWidget *p = q->parentWidget()) // reset the cursor on the native parent
|
||||
+ qt_x11_enforce_cursor(p);
|
||||
}
|
||||
|
||||
if (extra && !extra->mask.isEmpty() && q->internalWinId())
|
||||
--
|
||||
1.6.1
|
||||
|
|
@ -0,0 +1,47 @@
|
|||
diff -up qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp.gtk_init qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp
|
||||
--- qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp.gtk_init 2010-05-03 19:43:20.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp 2010-06-18 10:11:20.738800727 -0500
|
||||
@@ -35,6 +35,8 @@
|
||||
|
||||
namespace WebCore {
|
||||
|
||||
+typedef void gtkInitFunc(int *argc, char ***argv);
|
||||
+
|
||||
bool PluginPackage::fetchInfo()
|
||||
{
|
||||
if (!load())
|
||||
@@ -110,6 +112,8 @@ bool PluginPackage::load()
|
||||
NP_InitializeFuncPtr NP_Initialize;
|
||||
NPError npErr;
|
||||
|
||||
+ gtkInitFunc* gtkInit;
|
||||
+
|
||||
NP_Initialize = (NP_InitializeFuncPtr)m_module->resolve("NP_Initialize");
|
||||
m_NPP_Shutdown = (NPP_ShutdownProcPtr)m_module->resolve("NP_Shutdown");
|
||||
|
||||
@@ -127,6 +131,25 @@ bool PluginPackage::load()
|
||||
m_browserFuncs.getvalue = staticPluginQuirkRequiresGtkToolKit_NPN_GetValue;
|
||||
}
|
||||
|
||||
+ // WORKAROUND: Prevent gtk based plugin crashes such as BR# 40567 by
|
||||
+ // explicitly forcing the initializing of Gtk, i.e. calling gtk_init,
|
||||
+ // whenver the symbol is present in the plugin library loaded above.
|
||||
+ // Note that this workaround is based on code from the NSPluginClass ctor
|
||||
+ // in KDE's kdebase/apps/nsplugins/viewer/nsplugin.cpp file.
|
||||
+ gtkInit = (gtkInitFunc*)m_module->resolve("gtk_init");
|
||||
+ if (gtkInit) {
|
||||
+ // Prevent gtk_init() from replacing the X error handlers, since the Gtk
|
||||
+ // handlers abort when they receive an X error, thus killing the viewer.
|
||||
+#ifdef Q_WS_X11
|
||||
+ int (*old_error_handler)(Display*, XErrorEvent*) = XSetErrorHandler(0);
|
||||
+ int (*old_io_error_handler)(Display*) = XSetIOErrorHandler(0);
|
||||
+#endif
|
||||
+ gtkInit(0, 0);
|
||||
+#ifdef Q_WS_X11
|
||||
+ XSetErrorHandler(old_error_handler);
|
||||
+ XSetIOErrorHandler(old_io_error_handler);
|
||||
+#endif
|
||||
+ }
|
||||
#if defined(XP_UNIX)
|
||||
npErr = NP_Initialize(&m_browserFuncs, &m_pluginFuncs);
|
||||
#else
|
|
@ -0,0 +1,19 @@
|
|||
diff -up qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/PluginDatabase.cpp.pluginpath qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/PluginDatabase.cpp
|
||||
--- qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/PluginDatabase.cpp.pluginpath 2010-05-03 19:43:20.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.7.0-beta1/src/3rdparty/webkit/WebCore/plugins/PluginDatabase.cpp 2010-06-18 10:02:37.004788646 -0500
|
||||
@@ -345,6 +345,7 @@ Vector<String> PluginDatabase::defaultPl
|
||||
paths.append("/usr/lib/firefox/plugins");
|
||||
paths.append("/usr/lib64/browser-plugins");
|
||||
paths.append("/usr/lib/browser-plugins");
|
||||
+ paths.append("/usr/lib/mozilla/plugins-wrapped");
|
||||
paths.append("/usr/lib/mozilla/plugins");
|
||||
paths.append("/usr/local/netscape/plugins");
|
||||
paths.append("/opt/mozilla/plugins");
|
||||
@@ -355,6 +356,7 @@ Vector<String> PluginDatabase::defaultPl
|
||||
paths.append("/usr/lib/netscape/plugins-libc5");
|
||||
paths.append("/usr/lib/netscape/plugins-libc6");
|
||||
paths.append("/usr/lib64/netscape/plugins");
|
||||
+ paths.append("/usr/lib64/mozilla/plugins-wrapped");
|
||||
paths.append("/usr/lib64/mozilla/plugins");
|
||||
paths.append("/usr/lib/nsbrowser/plugins");
|
||||
paths.append("/usr/lib64/nsbrowser/plugins");
|
|
@ -0,0 +1,36 @@
|
|||
diff -up qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/embed.cpp.uic_multilib qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/embed.cpp
|
||||
--- qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/embed.cpp.uic_multilib 2010-05-03 19:43:25.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/embed.cpp 2010-06-25 14:11:21.815474310 -0500
|
||||
@@ -152,7 +152,7 @@ void Ui3Reader::embed(const char *projec
|
||||
for ( it = images.begin(); it != images.end(); ++it )
|
||||
out << "** " << *it << "\n";
|
||||
out << "**\n";
|
||||
- out << "** Created: " << QDateTime::currentDateTime().toString() << "\n";
|
||||
+ out << "** Created: " << "\n";
|
||||
out << "** by: The User Interface Compiler for Qt version " << QT_VERSION_STR << "\n";
|
||||
out << "**\n";
|
||||
out << "** WARNING! All changes made in this file will be lost!\n";
|
||||
diff -up qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/uic.cpp.uic_multilib qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/uic.cpp
|
||||
--- qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/uic.cpp.uic_multilib 2010-05-03 19:43:25.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic3/uic.cpp 2010-06-25 14:11:32.910460623 -0500
|
||||
@@ -146,7 +146,7 @@ void Uic::writeCopyrightHeader(DomUI *ui
|
||||
out << "/********************************************************************************\n";
|
||||
out << "** Form generated from reading UI file '" << QFileInfo(opt.inputFile).fileName() << "'\n";
|
||||
out << "**\n";
|
||||
- out << "** Created: " << QDateTime::currentDateTime().toString() << "\n";
|
||||
+ out << "** Created: " << "\n";
|
||||
out << "** " << QString::fromLatin1("by: Qt User Interface Compiler version %1\n").arg(QLatin1String(QT_VERSION_STR));
|
||||
out << "**\n";
|
||||
out << "** WARNING! All changes made in this file will be lost when recompiling UI file!\n";
|
||||
diff -up qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic/uic.cpp.uic_multilib qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic/uic.cpp
|
||||
--- qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic/uic.cpp.uic_multilib 2010-05-03 19:43:25.000000000 -0500
|
||||
+++ qt-everywhere-opensource-src-4.7.0-beta1/src/tools/uic/uic.cpp 2010-06-25 14:10:45.360711498 -0500
|
||||
@@ -139,7 +139,7 @@ void Uic::writeCopyrightHeader(DomUI *ui
|
||||
out << "/********************************************************************************\n";
|
||||
out << "** Form generated from reading UI file '" << QFileInfo(opt.inputFile).fileName() << "'\n";
|
||||
out << "**\n";
|
||||
- out << "** Created: " << QDateTime::currentDateTime().toString() << "\n";
|
||||
+ out << "** Created: " << "\n";
|
||||
out << "** " << QString::fromLatin1("by: Qt User Interface Compiler version %1\n").arg(QLatin1String(QT_VERSION_STR));
|
||||
out << "**\n";
|
||||
out << "** WARNING! All changes made in this file will be lost when recompiling UI file!\n";
|
|
@ -1,21 +0,0 @@
|
|||
diff -ur qt-orig/tools/qdoc3/qdoc3.pro qt-4.5.2/tools/qdoc3/qdoc3.pro
|
||||
--- qt-orig/tools/qdoc3/qdoc3.pro 2009-06-20 06:57:59.000000000 +0200
|
||||
+++ qt-4.5.2/tools/qdoc3/qdoc3.pro 2009-06-25 20:00:12.000000000 +0200
|
||||
@@ -99,3 +99,6 @@
|
||||
webxmlgenerator.cpp \
|
||||
yyindent.cpp
|
||||
|
||||
+TARGET= qdoc3
|
||||
+target.path = $$[QT_INSTALL_BINS]
|
||||
+INSTALLS += target
|
||||
diff -ur qt-orig/tools/tools.pro qt-4.5.2/tools/tools.pro
|
||||
--- qt-orig/tools/tools.pro 2009-06-20 06:57:59.000000000 +0200
|
||||
+++ qt-4.5.2/tools/tools.pro 2009-06-25 19:59:19.000000000 +0200
|
||||
@@ -13,6 +13,7 @@
|
||||
SUBDIRS += designer
|
||||
}
|
||||
SUBDIRS += linguist
|
||||
+ SUBDIRS += qdoc3
|
||||
wince*: SUBDIRS = qtestlib designer
|
||||
unix:!mac:!embedded:contains(QT_CONFIG, qt3support):SUBDIRS += qtconfig
|
||||
win32:!wince*:SUBDIRS += activeqt
|
|
@ -1,25 +0,0 @@
|
|||
diff -up qt-x11-opensource-src-4.5.2/src/3rdparty/webkit/WebCore/html/HTMLTokenizer.cpp.orig qt-x11-opensource-src-4.5.2/src/3rdparty/webkit/WebCore/html/HTMLTokenizer.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/3rdparty/webkit/WebCore/html/HTMLTokenizer.cpp.orig 2009-08-18 12:28:26.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/3rdparty/webkit/WebCore/html/HTMLTokenizer.cpp 2009-08-18 12:33:43.000000000 +0200
|
||||
@@ -867,7 +867,9 @@ HTMLTokenizer::State HTMLTokenizer::pars
|
||||
}
|
||||
} else {
|
||||
// FIXME: We should eventually colorize entities by sending them as a special token.
|
||||
- checkBuffer(11);
|
||||
+ // 12 bytes required: up to 10 bytes in m_cBuffer plus the
|
||||
+ // leading '&' and trailing ';'
|
||||
+ checkBuffer(12);
|
||||
*dest++ = '&';
|
||||
for (unsigned i = 0; i < cBufferPos; i++)
|
||||
dest[i] = m_cBuffer[i];
|
||||
@@ -878,7 +880,9 @@ HTMLTokenizer::State HTMLTokenizer::pars
|
||||
}
|
||||
}
|
||||
} else {
|
||||
- checkBuffer(10);
|
||||
+ // 11 bytes required: up to 10 bytes in m_cBuffer plus the
|
||||
+ // leading '&'
|
||||
+ checkBuffer(11);
|
||||
// ignore the sequence, add it to the buffer as plaintext
|
||||
*dest++ = '&';
|
||||
for (unsigned i = 0; i < cBufferPos; i++)
|
|
@ -1,12 +0,0 @@
|
|||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp.orig qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp.orig 2009-08-31 16:46:48.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp 2009-08-31 16:49:47.000000000 +0200
|
||||
@@ -377,7 +377,7 @@ QMultiMap<QSsl::AlternateNameEntryType,
|
||||
}
|
||||
|
||||
const char *altNameStr = reinterpret_cast<const char *>(q_ASN1_STRING_data(genName->d.ia5));
|
||||
- const QString altName = QLatin1String(QByteArray(altNameStr, len));
|
||||
+ const QString altName = QString::fromLatin1(altNameStr, len);
|
||||
if (genName->type == GEN_DNS)
|
||||
result.insert(QSsl::DnsEntry, altName);
|
||||
else if (genName->type == GEN_EMAIL)
|
|
@ -1,157 +0,0 @@
|
|||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp.openssl qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp.openssl 2009-06-20 06:57:57.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslcertificate.cpp 2009-08-26 12:14:32.000000000 +0200
|
||||
@@ -362,7 +362,7 @@ QMultiMap<QSsl::AlternateNameEntryType,
|
||||
if (!d->x509)
|
||||
return result;
|
||||
|
||||
- STACK *altNames = (STACK *)q_X509_get_ext_d2i(d->x509, NID_subject_alt_name, 0, 0);
|
||||
+ STACK_OF(GENERAL_NAME) *altNames = (STACK_OF(GENERAL_NAME) *)q_X509_get_ext_d2i(d->x509, NID_subject_alt_name, 0, 0);
|
||||
|
||||
if (altNames) {
|
||||
for (int i = 0; i < q_sk_GENERAL_NAME_num(altNames); ++i) {
|
||||
@@ -383,7 +383,7 @@ QMultiMap<QSsl::AlternateNameEntryType,
|
||||
else if (genName->type == GEN_EMAIL)
|
||||
result.insert(QSsl::EmailEntry, altName);
|
||||
}
|
||||
- q_sk_free(altNames);
|
||||
+ q_sk_free((STACK *)altNames);
|
||||
}
|
||||
|
||||
return result;
|
||||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp.openssl qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp.openssl 2009-06-20 06:57:57.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp 2009-08-26 10:40:09.000000000 +0200
|
||||
@@ -911,7 +911,7 @@ QSslCipher QSslSocketBackendPrivate::ses
|
||||
{
|
||||
if (!ssl || !ctx)
|
||||
return QSslCipher();
|
||||
- SSL_CIPHER *sessionCipher = q_SSL_get_current_cipher(ssl);
|
||||
+ SSL_CIPHER *sessionCipher = (SSL_CIPHER *)q_SSL_get_current_cipher(ssl);
|
||||
return sessionCipher ? QSslCipher_from_SSL_CIPHER(sessionCipher) : QSslCipher();
|
||||
}
|
||||
|
||||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols.cpp.openssl qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols.cpp.openssl 2009-08-26 10:36:25.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols.cpp 2009-08-26 12:40:30.000000000 +0200
|
||||
@@ -144,10 +144,10 @@ DEFINEFUNC(int, RAND_status, void, DUMMY
|
||||
DEFINEFUNC(void, RSA_free, RSA *a, a, return, DUMMYARG)
|
||||
DEFINEFUNC(void, sk_free, STACK *a, a, return, DUMMYARG)
|
||||
DEFINEFUNC(int, sk_num, STACK *a, a, return -1, return)
|
||||
-DEFINEFUNC2(char *, sk_value, STACK *a, a, int b, b, return 0, return)
|
||||
+DEFINEFUNC2(OSSL_SKVALUE_RTYPE *, sk_value, STACK *a, a, int b, b, return 0, return)
|
||||
DEFINEFUNC(int, SSL_accept, SSL *a, a, return -1, return)
|
||||
DEFINEFUNC(int, SSL_clear, SSL *a, a, return -1, return)
|
||||
-DEFINEFUNC3(char *, SSL_CIPHER_description, SSL_CIPHER *a, a, char *b, b, int c, c, return 0, return)
|
||||
+DEFINEFUNC3(char *, SSL_CIPHER_description, OSSL_MORECONST SSL_CIPHER *a, a, char *b, b, int c, c, return 0, return)
|
||||
DEFINEFUNC(int, SSL_connect, SSL *a, a, return -1, return)
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x00908000L
|
||||
// 0.9.8 broke SC and BC by changing this function's signature.
|
||||
@@ -157,7 +157,7 @@ DEFINEFUNC(int, SSL_CTX_check_private_ke
|
||||
#endif
|
||||
DEFINEFUNC4(long, SSL_CTX_ctrl, SSL_CTX *a, a, int b, b, long c, c, void *d, d, return -1, return)
|
||||
DEFINEFUNC(void, SSL_CTX_free, SSL_CTX *a, a, return, DUMMYARG)
|
||||
-DEFINEFUNC(SSL_CTX *, SSL_CTX_new, SSL_METHOD *a, a, return 0, return)
|
||||
+DEFINEFUNC(SSL_CTX *, SSL_CTX_new, OSSL_MORECONST SSL_METHOD *a, a, return 0, return)
|
||||
DEFINEFUNC2(int, SSL_CTX_set_cipher_list, SSL_CTX *a, a, const char *b, b, return -1, return)
|
||||
DEFINEFUNC(int, SSL_CTX_set_default_verify_paths, SSL_CTX *a, a, return -1, return)
|
||||
DEFINEFUNC3(void, SSL_CTX_set_verify, SSL_CTX *a, a, int b, b, int (*c)(int, X509_STORE_CTX *), c, return, DUMMYARG)
|
||||
@@ -174,7 +174,7 @@ DEFINEFUNC(STACK_OF(SSL_CIPHER) *, SSL_g
|
||||
#else
|
||||
DEFINEFUNC(STACK_OF(SSL_CIPHER) *, SSL_get_ciphers, SSL *a, a, return 0, return)
|
||||
#endif
|
||||
-DEFINEFUNC(SSL_CIPHER *, SSL_get_current_cipher, SSL *a, a, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_CIPHER *, SSL_get_current_cipher, SSL *a, a, return 0, return)
|
||||
DEFINEFUNC2(int, SSL_get_error, SSL *a, a, int b, b, return -1, return)
|
||||
DEFINEFUNC(STACK_OF(X509) *, SSL_get_peer_cert_chain, SSL *a, a, return 0, return)
|
||||
DEFINEFUNC(X509 *, SSL_get_peer_certificate, SSL *a, a, return 0, return)
|
||||
@@ -192,14 +192,14 @@ DEFINEFUNC3(void, SSL_set_bio, SSL *a, a
|
||||
DEFINEFUNC(void, SSL_set_accept_state, SSL *a, a, return, DUMMYARG)
|
||||
DEFINEFUNC(void, SSL_set_connect_state, SSL *a, a, return, DUMMYARG)
|
||||
DEFINEFUNC(int, SSL_shutdown, SSL *a, a, return -1, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv2_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv3_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv23_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, TLSv1_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv2_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv3_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, SSLv23_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
-DEFINEFUNC(SSL_METHOD *, TLSv1_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv2_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv3_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv23_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, TLSv1_client_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv2_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv3_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, SSLv23_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
+DEFINEFUNC(OSSL_MORECONST SSL_METHOD *, TLSv1_server_method, DUMMYARG, DUMMYARG, return 0, return)
|
||||
DEFINEFUNC3(int, SSL_write, SSL *a, a, const void *b, b, int c, c, return -1, return)
|
||||
DEFINEFUNC2(int, X509_cmp, X509 *a, a, X509 *b, b, return -1, return)
|
||||
#ifndef SSLEAY_MACROS
|
||||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols_p.h.openssl qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols_p.h
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols_p.h.openssl 2009-06-20 06:57:57.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl_symbols_p.h 2009-08-26 10:35:25.000000000 +0200
|
||||
@@ -254,12 +254,20 @@ int q_PEM_write_bio_RSA_PUBKEY(BIO *a, R
|
||||
void q_RAND_seed(const void *a, int b);
|
||||
int q_RAND_status();
|
||||
void q_RSA_free(RSA *a);
|
||||
+#if OPENSSL_VERSION_NUMBER >= 0x10000000L
|
||||
+#define STACK _STACK
|
||||
+#define OSSL_SKVALUE_RTYPE void
|
||||
+#define OSSL_MORECONST const
|
||||
+#else
|
||||
+#define OSSL_SKVALUE_RTYPE char
|
||||
+#define OSSL_MORECONST
|
||||
+#endif
|
||||
void q_sk_free(STACK *a);
|
||||
int q_sk_num(STACK *a);
|
||||
-char * q_sk_value(STACK *a, int b);
|
||||
+OSSL_SKVALUE_RTYPE * q_sk_value(STACK *a, int b);
|
||||
int q_SSL_accept(SSL *a);
|
||||
int q_SSL_clear(SSL *a);
|
||||
-char *q_SSL_CIPHER_description(SSL_CIPHER *a, char *b, int c);
|
||||
+char *q_SSL_CIPHER_description(OSSL_MORECONST SSL_CIPHER *a, char *b, int c);
|
||||
int q_SSL_connect(SSL *a);
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x00908000L
|
||||
// 0.9.8 broke SC and BC by changing this function's signature.
|
||||
@@ -269,7 +277,7 @@ int q_SSL_CTX_check_private_key(SSL_CTX
|
||||
#endif
|
||||
long q_SSL_CTX_ctrl(SSL_CTX *a, int b, long c, void *d);
|
||||
void q_SSL_CTX_free(SSL_CTX *a);
|
||||
-SSL_CTX *q_SSL_CTX_new(SSL_METHOD *a);
|
||||
+SSL_CTX *q_SSL_CTX_new(OSSL_MORECONST SSL_METHOD *a);
|
||||
int q_SSL_CTX_set_cipher_list(SSL_CTX *a, const char *b);
|
||||
int q_SSL_CTX_set_default_verify_paths(SSL_CTX *a);
|
||||
void q_SSL_CTX_set_verify(SSL_CTX *a, int b, int (*c)(int, X509_STORE_CTX *));
|
||||
@@ -286,7 +294,7 @@ STACK_OF(SSL_CIPHER) *q_SSL_get_ciphers(
|
||||
#else
|
||||
STACK_OF(SSL_CIPHER) *q_SSL_get_ciphers(SSL *a);
|
||||
#endif
|
||||
-SSL_CIPHER *q_SSL_get_current_cipher(SSL *a);
|
||||
+OSSL_MORECONST SSL_CIPHER *q_SSL_get_current_cipher(SSL *a);
|
||||
int q_SSL_get_error(SSL *a, int b);
|
||||
STACK_OF(X509) *q_SSL_get_peer_cert_chain(SSL *a);
|
||||
X509 *q_SSL_get_peer_certificate(SSL *a);
|
||||
@@ -304,14 +312,14 @@ void q_SSL_set_bio(SSL *a, BIO *b, BIO *
|
||||
void q_SSL_set_accept_state(SSL *a);
|
||||
void q_SSL_set_connect_state(SSL *a);
|
||||
int q_SSL_shutdown(SSL *a);
|
||||
-SSL_METHOD *q_SSLv2_client_method();
|
||||
-SSL_METHOD *q_SSLv3_client_method();
|
||||
-SSL_METHOD *q_SSLv23_client_method();
|
||||
-SSL_METHOD *q_TLSv1_client_method();
|
||||
-SSL_METHOD *q_SSLv2_server_method();
|
||||
-SSL_METHOD *q_SSLv3_server_method();
|
||||
-SSL_METHOD *q_SSLv23_server_method();
|
||||
-SSL_METHOD *q_TLSv1_server_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv2_client_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv3_client_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv23_client_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_TLSv1_client_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv2_server_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv3_server_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_SSLv23_server_method();
|
||||
+OSSL_MORECONST SSL_METHOD *q_TLSv1_server_method();
|
||||
int q_SSL_write(SSL *a, const void *b, int c);
|
||||
int q_X509_cmp(X509 *a, X509 *b);
|
||||
#ifdef SSLEAY_MACROS
|
|
@ -1,42 +0,0 @@
|
|||
diff -up qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp.me qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp
|
||||
--- qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp.me 2009-09-09 14:28:38.000000000 +0200
|
||||
+++ qt-x11-opensource-src-4.5.2/src/network/ssl/qsslsocket_openssl.cpp 2009-09-09 15:00:07.000000000 +0200
|
||||
@@ -482,31 +482,20 @@ void QSslSocketPrivate::resetDefaultCiph
|
||||
|
||||
QList<QSslCertificate> QSslSocketPrivate::systemCaCertificates()
|
||||
{
|
||||
-#ifdef QQ_OS_UNIX
|
||||
+ QFile caBundle;
|
||||
+
|
||||
+#ifdef Q_OS_UNIX
|
||||
// Check known locations for the system's default bundle. ### On Windows,
|
||||
// we should use CAPI to find the bundle, and not rely on default unix
|
||||
// locations.
|
||||
- const char *standardLocations[] = {"/etc/ssl/certs/",
|
||||
-#if 0
|
||||
- // KDE uses KConfig for its SSL store,
|
||||
- // but it also stores the bundle at
|
||||
- // this location
|
||||
- "$HOME/.kde/share/apps/kssl/ca-bundle.crt",
|
||||
-#endif
|
||||
- 0};
|
||||
- const char **it = standardLocations;
|
||||
- QStringList nameFilter;
|
||||
- nameFilter << QLatin1String("*.pem") << QLatin1String("*.crt");
|
||||
- while (*it) {
|
||||
- if (QDirIterator(QLatin1String(*it), nameFilter).hasNext())
|
||||
- return certificatesFromPath(QLatin1String(*it));
|
||||
- ++it;
|
||||
- }
|
||||
+ caBundle.setFileName(QLatin1String("/etc/pki/tls/certs/ca-bundle.crt"));
|
||||
+ if (caBundle.open(QIODevice::ReadOnly | QIODevice::Text))
|
||||
+ return QSslCertificate::fromDevice(&caBundle);
|
||||
#endif
|
||||
|
||||
// Qt provides a default bundle when we cannot detect the system's default
|
||||
// bundle.
|
||||
- QFile caBundle(QLatin1String(":/trolltech/network/ssl/qt-ca-bundle.crt"));
|
||||
+ caBundle.setFileName(QLatin1String(":/trolltech/network/ssl/qt-ca-bundle.crt"));
|
||||
if (caBundle.open(QIODevice::ReadOnly | QIODevice::Text))
|
||||
return QSslCertificate::fromDevice(&caBundle);
|
||||
|
|
@ -1,92 +0,0 @@
|
|||
From 9e5fa633913ef952ca4ef5312fe396bcfc885321 Mon Sep 17 00:00:00 2001
|
||||
From: Denis Dzyubenko <denis.dzyubenko@nokia.com>
|
||||
Date: Wed, 22 Jul 2009 17:12:17 +0200
|
||||
Subject: [PATCH] Revert "Added a check that X11 timestamp goes forward only."
|
||||
|
||||
In some cases we might get an invalid timestamp that is far away in
|
||||
the future, so remembering it will break all consequent X calls that
|
||||
require a timestamp because it just contains junk (for example
|
||||
clipboard will stop working). This happens with XIM+SCIM pair -
|
||||
whenever we start input method and type something to the widget, we
|
||||
get a XKeyPress event with a commited string, however the 'serial' and
|
||||
'time' members of the XEvent structure are not initialized (according
|
||||
to valgrind) and contain junk.
|
||||
|
||||
This reverts commit 2ed015b8a0ffad63f0f59b0e2255057f416895fb.
|
||||
|
||||
Reviewed-By: Brad
|
||||
---
|
||||
src/gui/kernel/qapplication_x11.cpp | 35 +++++++++++++++--------------------
|
||||
1 files changed, 15 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/src/gui/kernel/qapplication_x11.cpp b/src/gui/kernel/qapplication_x11.cpp
|
||||
index 163ceb6..abedfd6 100644
|
||||
--- a/src/gui/kernel/qapplication_x11.cpp
|
||||
+++ b/src/gui/kernel/qapplication_x11.cpp
|
||||
@@ -3142,48 +3142,43 @@ int QApplication::x11ProcessEvent(XEvent* event)
|
||||
#ifdef ALIEN_DEBUG
|
||||
//qDebug() << "QApplication::x11ProcessEvent:" << event->type;
|
||||
#endif
|
||||
- Time time = 0, userTime = 0;
|
||||
switch (event->type) {
|
||||
case ButtonPress:
|
||||
pressed_window = event->xbutton.window;
|
||||
- userTime = event->xbutton.time;
|
||||
+ X11->userTime = event->xbutton.time;
|
||||
// fallthrough intended
|
||||
case ButtonRelease:
|
||||
- time = event->xbutton.time;
|
||||
+ X11->time = event->xbutton.time;
|
||||
break;
|
||||
case MotionNotify:
|
||||
- time = event->xmotion.time;
|
||||
+ X11->time = event->xmotion.time;
|
||||
break;
|
||||
case XKeyPress:
|
||||
- userTime = event->xkey.time;
|
||||
+ X11->userTime = event->xkey.time;
|
||||
// fallthrough intended
|
||||
case XKeyRelease:
|
||||
- time = event->xkey.time;
|
||||
+ X11->time = event->xkey.time;
|
||||
break;
|
||||
case PropertyNotify:
|
||||
- time = event->xproperty.time;
|
||||
+ X11->time = event->xproperty.time;
|
||||
break;
|
||||
case EnterNotify:
|
||||
case LeaveNotify:
|
||||
- time = event->xcrossing.time;
|
||||
+ X11->time = event->xcrossing.time;
|
||||
break;
|
||||
case SelectionClear:
|
||||
- time = event->xselectionclear.time;
|
||||
+ X11->time = event->xselectionclear.time;
|
||||
break;
|
||||
default:
|
||||
-#ifndef QT_NO_XFIXES
|
||||
- if (X11->use_xfixes && event->type == (X11->xfixes_eventbase + XFixesSelectionNotify)) {
|
||||
- XFixesSelectionNotifyEvent *req =
|
||||
- reinterpret_cast<XFixesSelectionNotifyEvent *>(event);
|
||||
- time = req->selection_timestamp;
|
||||
- }
|
||||
-#endif
|
||||
break;
|
||||
}
|
||||
- if (time > X11->time)
|
||||
- X11->time = time;
|
||||
- if (userTime > X11->userTime)
|
||||
- X11->userTime = userTime;
|
||||
+#ifndef QT_NO_XFIXES
|
||||
+ if (X11->use_xfixes && event->type == (X11->xfixes_eventbase + XFixesSelectionNotify)) {
|
||||
+ XFixesSelectionNotifyEvent *req =
|
||||
+ reinterpret_cast<XFixesSelectionNotifyEvent *>(event);
|
||||
+ X11->time = req->selection_timestamp;
|
||||
+ }
|
||||
+#endif
|
||||
|
||||
QETWidget *widget = (QETWidget*)QWidget::find((WId)event->xany.window);
|
||||
|
||||
--
|
||||
1.6.1
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
diff -up qt-x11-opensource-src-4.5.3/src/network/ssl/qsslsocket_openssl.cpp.system_ca_certificates qt-x11-opensource-src-4.5.3/src/network/ssl/qsslsocket_openssl.cpp
|
||||
--- qt-x11-opensource-src-4.5.3/src/network/ssl/qsslsocket_openssl.cpp.system_ca_certificates 2009-09-29 06:01:38.000000000 -0500
|
||||
+++ qt-x11-opensource-src-4.5.3/src/network/ssl/qsslsocket_openssl.cpp 2009-10-02 11:20:10.674662746 -0500
|
||||
@@ -482,8 +482,20 @@ void QSslSocketPrivate::resetDefaultCiph
|
||||
|
||||
QList<QSslCertificate> QSslSocketPrivate::systemCaCertificates()
|
||||
{
|
||||
+
|
||||
+ QFile caBundle;
|
||||
+
|
||||
+#ifdef Q_OS_UNIX
|
||||
+ // Check known locations for the system's default bundle. ### On Windows,
|
||||
+ // we should use CAPI to find the bundle, and not rely on default unix
|
||||
+ // locations.
|
||||
+ caBundle.setFileName(QLatin1String("/etc/pki/tls/certs/ca-bundle.crt"));
|
||||
+ if (caBundle.open(QIODevice::ReadOnly | QIODevice::Text))
|
||||
+ return QSslCertificate::fromDevice(&caBundle);
|
||||
+#endif
|
||||
+
|
||||
// Qt provides a default bundle of certificates
|
||||
- QFile caBundle(QLatin1String(":/trolltech/network/ssl/qt-ca-bundle.crt"));
|
||||
+ caBundle.setFileName(QLatin1String(":/trolltech/network/ssl/qt-ca-bundle.crt"));
|
||||
if (caBundle.open(QIODevice::ReadOnly | QIODevice::Text))
|
||||
return QSslCertificate::fromDevice(&caBundle);
|
||||
|
506
qt.spec
506
qt.spec
|
@ -4,19 +4,22 @@
|
|||
# -no-pch disables precompiled headers, make ccache-friendly
|
||||
%define no_pch -no-pch
|
||||
|
||||
%define _default_patch_fuzz 2
|
||||
%define _default_patch_fuzz 3
|
||||
|
||||
# enable kde-qt integration/patches (currently a no-op)
|
||||
%define kde_qt 1
|
||||
|
||||
Summary: Qt toolkit
|
||||
Name: qt
|
||||
Epoch: 1
|
||||
Version: 4.5.2
|
||||
Release: 20%{?dist}
|
||||
Version: 4.6.3
|
||||
Release: 9%{?dist}
|
||||
|
||||
# See LGPL_EXCEPTIONS.txt, LICENSE.GPL3, respectively, for exception details
|
||||
License: LGPLv2 with exceptions or GPLv3 with exceptions
|
||||
Group: System Environment/Libraries
|
||||
Url: http://www.qtsoftware.com/
|
||||
Source0: ftp://ftp.trolltech.com/qt/source/qt-x11-opensource-src-%{version}.tar.bz2
|
||||
Source0: http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-%{version}.tar.gz
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
Obsoletes: qt4 < %{version}-%{release}
|
||||
Provides: qt4 = %{version}-%{release}
|
||||
|
@ -31,6 +34,7 @@ Source5: qconfig-multilib.h
|
|||
# multilib hacks
|
||||
Patch2: qt-x11-opensource-src-4.2.2-multilib-optflags.patch
|
||||
Patch3: qt-x11-opensource-src-4.2.2-multilib-QMAKEPATH.patch
|
||||
Patch4: qt-everywhere-opensource-src-4.7.0-beta1-uic_multilib.patch
|
||||
Patch5: qt-all-opensource-src-4.4.0-rc1-as_IN-437440.patch
|
||||
# hack around gcc/ppc crasher, http://bugzilla.redhat.com/492185
|
||||
Patch13: qt-x11-opensource-src-4.5.0-gcc_hack.patch
|
||||
|
@ -40,34 +44,67 @@ Patch16: qt-x11-opensource-src-4.5.1-kde4_plugins.patch
|
|||
# make PulseAudio the default device in Phonon
|
||||
Patch17: qt-x11-opensource-src-4.5.2-pulseaudio.patch
|
||||
Patch19: qt-x11-opensource-src-4.5.1-phonon.patch
|
||||
Patch21: qt-x11-opensource-src-4.5.2-gst-pulsaudio.patch
|
||||
Patch21: qt-everywhere-opensource-src-4.6.0-gst-pulsaudio.patch
|
||||
# use system ca-bundle certs, http://bugzilla.redhat.com/521911
|
||||
Patch22: qt-x11-opensource-src-4.5.2-system_ca_certificates.patch
|
||||
Patch22: qt-x11-opensource-src-4.5.3-system_ca_certificates.patch
|
||||
Requires: ca-certificates
|
||||
# may be upstreamable, not sure yet
|
||||
# workaround for gdal/grass crashers wrt glib_eventloop null deref's
|
||||
Patch23: qt-everywhere-opensource-src-4.6.3-glib_eventloop_nullcheck.patch
|
||||
|
||||
## upstreamable bits
|
||||
# http://bugzilla.redhat.com/485677
|
||||
Patch51: qt-x11-opensource-src-4.5.0-qdoc3.patch
|
||||
Patch52: qt-4.5-sparc64.patch
|
||||
Patch51: qt-everywhere-opensource-src-4.6.0-beta1-qdoc3.patch
|
||||
# fix invalid inline assembly in qatomic_{i386,x86_64}.h (de)ref implementations
|
||||
Patch53: qt-x11-opensource-src-4.5.0-fix-qatomic-inline-asm.patch
|
||||
# fix invalid assumptions about mysql_config --libs
|
||||
# http://bugzilla.redhat.com/440673
|
||||
Patch54: qt-x11-opensource-src-4.5.1-mysql_config.patch
|
||||
Patch55: qt-x11-opensource-src-4.5.2-timestamp.patch
|
||||
# compile with openssl-1.0
|
||||
Patch56: qt-x11-opensource-src-4.5.2-ossl10.patch
|
||||
# http://bugs.kde.org/show_bug.cgi?id=180051#c22
|
||||
Patch55: qt-everywhere-opensource-src-4.6.2-cups.patch
|
||||
# fix type cast issue on s390x
|
||||
Patch56: qt-everywhere-opensource-src-4.6.2-webkit-s390x.patch
|
||||
# fix type cast issue on sparc64
|
||||
Patch57: qt-everywhere-opensource-src-4.6.2-webkit-sparc64.patch
|
||||
# qtwebkit to search nspluginwrapper paths too
|
||||
Patch58: qt-everywhere-opensource-src-4.7.0-beta1-qtwebkit_pluginpath.patch
|
||||
|
||||
# security patches
|
||||
Patch100: qt-x11-opensource-src-4.5.2-CVE-2009-1725.patch
|
||||
Patch101: qt-x11-opensource-src-4.5.2-CVE-2009-2700.patch
|
||||
# upstream or security patches
|
||||
# https://bugs.webkit.org/show_bug.cgi?id=40567
|
||||
Patch100: qt-everywhere-opensource-src-4.7.0-beta1-qtwebkit_gtk_init.patch
|
||||
# http://bugreports.qt.nokia.com/browse/QTBUG-6185
|
||||
# http://qt.gitorious.org/qt/staging/commit/9e9a7bc29319d52c3e563bc2c5282cb7e6890eba
|
||||
Patch101: qt-everywhere-opensource-src-4.7.0-QTBUG-6185.patch
|
||||
Patch104: qt-everywhere-opensource-src-4.6.2-cve-2010-0051-lax-css-parsing-cross-domain-theft.patch
|
||||
Patch106: qt-everywhere-opensource-src-4.6.2-cve-2010-0656.patch
|
||||
Patch108: qt-everywhere-opensource-src-4.6.2-cve-2010-0648.patch
|
||||
Patch109: qt-everywhere-opensource-src-4.6.3-CVE-2010-1303_1304.patch
|
||||
Patch110: qt-everywhere-opensource-src-4.6.3-CVE-2010-1392.patch
|
||||
Patch111: qt-everywhere-opensource-src-4.6.3-CVE-2010-1396.patch
|
||||
Patch112: qt-everywhere-opensource-src-4.6.3-CVE-2010-1397.patch
|
||||
Patch113: qt-everywhere-opensource-src-4.6.3-CVE-2010-1398.patch
|
||||
Patch114: qt-everywhere-opensource-src-4.6.3-CVE-2010-1400.patch
|
||||
Patch115: qt-everywhere-opensource-src-4.6.3-CVE-2010-1412.patch
|
||||
Patch116: qt-everywhere-opensource-src-4.6.3-CVE-2010-1770.patch
|
||||
Patch117: qt-everywhere-opensource-src-4.6.3-CVE-2010-1773.patch
|
||||
Patch118: qt-everywhere-opensource-src-4.6.3-CVE-2010-1774.patch
|
||||
Patch119: qt-everywhere-opensource-src-4.6.3-CVE-2010-1119.patch
|
||||
Patch120: qt-everywhere-opensource-src-4.6.3-CVE-2010-1778.patch
|
||||
|
||||
# switch to kde-qt branches, qt-copy doesn't exist anymore
|
||||
Patch200: kde-qt-patches-20090820git.patch
|
||||
# these patches are not merged yet in kde-qt branches
|
||||
Patch201: 0118-qtcopy-define.diff
|
||||
Patch202: 0283-do-not-deduce-scrollbar-extent-twice.diff
|
||||
Patch203: 0285-qgv-dontshowchildren.diff
|
||||
# kde-qt git patches
|
||||
Patch201: 0001-This-patch-uses-object-name-as-a-fallback-for-window.patch
|
||||
Patch202: 0002-This-patch-makes-override-redirect-windows-popup-men.patch
|
||||
Patch203: 0003-This-patch-changes-QObjectPrivateVersion-thus-preven.patch
|
||||
Patch204: 0004-This-patch-adds-support-for-using-isystem-to-allow-p.patch
|
||||
Patch205: 0005-When-tabs-are-inserted-or-removed-in-a-QTabBar.patch
|
||||
Patch206: 0006-Fix-configure.exe-to-do-an-out-of-source-build-on-wi.patch
|
||||
Patch207: 0007-When-using-qmake-outside-qt-src-tree-it-sometimes-ge.patch
|
||||
Patch208: 0008-This-patch-makes-the-raster-graphics-system-use-shar.patch
|
||||
Patch209: 0009-Restore-a-section-of-the-file-that-got-removed-due-t.patch
|
||||
Patch212: 0012-Add-context-to-tr-calls-in-QShortcut.patch
|
||||
Patch217: http://qt.gitorious.org/+kde-developers/qt/kde-qt/commit/55ef01d93f8257b5927660290fc1ead0b2b74ec9.patch
|
||||
# QTBUG-9793
|
||||
Patch218: http://qt.gitorious.org/qt/qt/commit/0ebc9783d8ca0c4b27208bbc002c53c52c19ab4c.patch
|
||||
|
||||
Source10: http://gstreamer.freedesktop.org/data/images/artwork/gstreamer-logo.svg
|
||||
Source11: hi16-phonon-gstreamer.png
|
||||
|
@ -96,11 +133,18 @@ Source31: hi48-app-qt4-logo.png
|
|||
%define odbc -plugin-sql-odbc
|
||||
%define psql -plugin-sql-psql
|
||||
%define sqlite -plugin-sql-sqlite
|
||||
%define tds -plugin-sql-tds
|
||||
%define phonon -phonon
|
||||
%define phonon_backend -phonon-backend
|
||||
%define phonon_version 4.3.1
|
||||
%if 0%{?rhel}
|
||||
# if building with -phonon, define to internal version (ie, Obsolete external phonon)
|
||||
%define phonon_internal 1
|
||||
# if -phonon-backend, include in packaging (else it's omitted)
|
||||
%define phonon_backend_packaged 1
|
||||
%endif
|
||||
%define phonon_version 4.3.50
|
||||
%define phonon_version_major 4.3
|
||||
%define phonon_release 100
|
||||
%define phonon_release 1
|
||||
%define webkit -webkit
|
||||
%define gtkstyle -gtkstyle
|
||||
%define nas -no-nas-sound
|
||||
|
@ -122,8 +166,11 @@ Source31: hi48-app-qt4-logo.png
|
|||
%define _qt4_sysconfdir %{_sysconfdir}
|
||||
%define _qt4_translationdir %{_datadir}/qt4/translations
|
||||
|
||||
%if "%{_qt4_libdir}" != "%{_libdir}"
|
||||
Prereq: /etc/ld.so.conf.d
|
||||
%endif
|
||||
|
||||
BuildRequires: alsa-lib-devel
|
||||
BuildRequires: dbus-devel >= 0.62
|
||||
BuildRequires: cups-devel
|
||||
BuildRequires: desktop-file-utils
|
||||
|
@ -178,14 +225,14 @@ BuildRequires: unixODBC-devel
|
|||
BuildRequires: sqlite-devel
|
||||
%endif
|
||||
|
||||
%if "%{?tds}" != "-no-sql-tds"
|
||||
BuildRequires: freetds-devel
|
||||
%endif
|
||||
|
||||
Obsoletes: qgtkstyle < 0.1
|
||||
Provides: qgtkstyle = 0.1-1
|
||||
Obsoletes: qt4-config < 4.5.0
|
||||
Provides: qt4-config = %{version}-%{release}
|
||||
Obsoletes: qt4-sqlite < 4.5.0
|
||||
Provides: qt4-sqlite = %{version}-%{release}
|
||||
Obsoletes: qt-sqlite < %{?epoch:%{epoch}:}4.5.0
|
||||
Provides: qt-sqlite = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
|
||||
%description
|
||||
Qt is a software toolkit for developing applications.
|
||||
|
@ -237,12 +284,16 @@ Requires: libjpeg-devel
|
|||
Requires: pkgconfig
|
||||
%if 0%{?phonon:1}
|
||||
Provides: qt4-phonon-devel = %{version}-%{release}
|
||||
%endif
|
||||
%if 0%{?phonon_internal}
|
||||
Obsoletes: phonon-devel < 4.3.1-100
|
||||
Provides: phonon-devel = %{phonon_version}-%{phonon_release}
|
||||
%endif
|
||||
%if 0%{?webkit:1}
|
||||
Obsoletes: WebKit-qt-devel < 1.0.0-1
|
||||
Provides: WebKit-qt-devel = 1.0.0-1
|
||||
Provides: qt4-webkit-devel = %{version}-%{release}
|
||||
Provides: qt4-webkit-devel%{?_isa} = %{version}-%{release}
|
||||
%endif
|
||||
Obsoletes: qt4-designer < %{version}-%{release}
|
||||
Provides: qt4-designer = %{version}-%{release}
|
||||
|
@ -252,6 +303,8 @@ Obsoletes: qt4-devel < %{version}-%{release}
|
|||
Provides: qt4-devel = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-devel%{?_isa} = %{version}-%{release}}
|
||||
Provides: qt4-static = %{version}-%{release}
|
||||
Provides: qt-assistant-adp-devel = %{version}-0.%{release}
|
||||
%{?_isa:Provides: qt-assistant-adp-devel%{?_isa} = %{version}-0.%{release}}
|
||||
|
||||
%description devel
|
||||
This package contains the files necessary to develop
|
||||
|
@ -277,6 +330,7 @@ Obsoletes: qt4-MySQL < %{version}-%{release}
|
|||
Provides: qt4-MySQL = %{version}-%{release}
|
||||
Obsoletes: qt4-mysql < %{version}-%{release}
|
||||
Provides: qt4-mysql = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-mysql%{?_isa} = %{version}-%{release}}
|
||||
|
||||
%description mysql
|
||||
%{summary}.
|
||||
|
@ -290,6 +344,7 @@ Obsoletes: qt4-ODBC < %{version}-%{release}
|
|||
Provides: qt4-ODBC = %{version}-%{release}
|
||||
Obsoletes: qt4-odbc < %{version}-%{release}
|
||||
Provides: qt4-odbc = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-odbc%{?_isa} = %{version}-%{release}}
|
||||
|
||||
%description odbc
|
||||
%{summary}.
|
||||
|
@ -303,30 +358,62 @@ Obsoletes: qt4-PostgreSQL < %{version}-%{release}
|
|||
Provides: qt4-PostgreSQL = %{version}-%{release}
|
||||
Obsoletes: qt4-postgresql < %{version}-%{release}
|
||||
Provides: qt4-postgresql = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-postgresql%{?_isa} = %{version}-%{release}}
|
||||
|
||||
%description postgresql
|
||||
%{summary}.
|
||||
|
||||
%package sqlite
|
||||
Summary: SQLite driver for Qt's SQL classes
|
||||
Group: System Environment/Libraries
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Obsoletes: qt4-SQLite < %{version}-%{release}
|
||||
Provides: qt4-SQLite = %{version}-%{release}
|
||||
Obsoletes: qt4-sqlite < %{version}-%{release}
|
||||
Provides: qt4-sqlite = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-sqlite%{?_isa} = %{version}-%{release}}
|
||||
|
||||
%description sqlite
|
||||
%{summary}.
|
||||
|
||||
%package tds
|
||||
Summary: TDS driver for Qt's SQL classes
|
||||
Group: System Environment/Libraries
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Provides: qt4-tds = %{version}-%{release}
|
||||
%{?_isa:Provides: qt4-tds%{?_isa} = %{version}-%{release}}
|
||||
|
||||
%description tds
|
||||
%{summary}.
|
||||
|
||||
%package x11
|
||||
Summary: Qt GUI-related libraries
|
||||
Group: System Environment/Libraries
|
||||
%if 0%{?phonon:1}
|
||||
Requires: phonon-backend%{?_isa} >= %{phonon_version_major}
|
||||
%endif
|
||||
%if 0%{?phonon_internal}
|
||||
Obsoletes: phonon < 4.3.1-100
|
||||
Provides: phonon = %{phonon_version}-%{phonon_release}
|
||||
Provides: phonon%{?_isa} = %{phonon_version}-%{phonon_release}
|
||||
Requires: phonon-backend%{?_isa} >= %{phonon_version_major}
|
||||
Provides: qt4-phonon = %{version}-%{release}
|
||||
%endif
|
||||
%if 0%{?webkit:1}
|
||||
Obsoletes: WebKit-qt < 1.0.0-1
|
||||
Provides: WebKit-qt = 1.0.0-1
|
||||
Provides: qt4-webkit = %{version}-%{release}
|
||||
Provides: qt4-webkit%{?_isa} = %{version}-%{release}
|
||||
%endif
|
||||
%if 0%{?sqlite:1}
|
||||
Requires: %{name}-sqlite%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
%endif
|
||||
Provides: qt4-assistant = %{version}-%{release}
|
||||
Provides: %{name}-assistant = %{version}-%{release}
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Obsoletes: qt4-x11 < %{version}-%{release}
|
||||
Provides: qt4-x11 = %{version}-%{release}
|
||||
Provides: qt-assistant-adp = %{version}-0.%{release}
|
||||
%{?_isa:Provides: qt-assistant-adp%{?_isa} = %{version}-0.%{release}}
|
||||
Requires(post): /sbin/ldconfig
|
||||
Requires(postun): /sbin/ldconfig
|
||||
|
||||
|
@ -335,7 +422,7 @@ Qt libraries used for drawing widgets and OpenGL items.
|
|||
|
||||
|
||||
%prep
|
||||
%setup -q -n qt-x11-opensource-src-%{version}
|
||||
%setup -q -n qt-everywhere-opensource-src-%{version}
|
||||
|
||||
# don't use -b on mkspec files, else they get installed too.
|
||||
# multilib hacks no longer required
|
||||
|
@ -343,6 +430,8 @@ Qt libraries used for drawing widgets and OpenGL items.
|
|||
%if "%{_qt4_datadir}" != "%{_qt4_prefix}"
|
||||
%patch3 -p1 -b .multilib-QMAKEPATH
|
||||
%endif
|
||||
%patch4 -p1 -b .uic_multilib
|
||||
|
||||
%patch5 -p1 -b .bz#437440-as_IN-437440
|
||||
%patch13 -p1 -b .gcc_hack
|
||||
%patch15 -p1 -b .enable_ft_lcdfilter
|
||||
|
@ -351,35 +440,66 @@ Qt libraries used for drawing widgets and OpenGL items.
|
|||
%patch19 -p1 -b .servicesfile
|
||||
%patch21 -p1 -b .gst-pulsaudio
|
||||
%patch22 -p1 -b .system_ca_certificates
|
||||
%patch23 -p1 -b .glib_eventloop_nullcheck
|
||||
%patch51 -p1 -b .qdoc3
|
||||
%patch52 -p1 -b .sparc64
|
||||
## TODO: still worth carrying? if so, upstream it.
|
||||
%patch53 -p1 -b .qatomic-inline-asm
|
||||
## TODO: upstream me
|
||||
%patch54 -p1 -b .mysql_config
|
||||
%patch55 -p1 -b .timestamp
|
||||
%patch56 -p1 -b .ossl10
|
||||
%patch55 -p1 -b .cups-1
|
||||
%patch56 -p1 -b .typecast_s390x
|
||||
%patch57 -p1 -b .typecast_sparc64
|
||||
%patch58 -p1 -b .qtwebkit_pluginpath
|
||||
|
||||
# upstream patches
|
||||
%patch100 -p1 -b .qtwebkit_gtk_init
|
||||
%patch101 -p1 -b .QTBUG-6185
|
||||
|
||||
# security fixes
|
||||
%patch100 -p1 -b .CVE-2009-1725
|
||||
%patch101 -p1 -b .CVE-2009-2700
|
||||
%patch104 -p1 -b .cve-2010-0051-lax-css-parsing-cross-domain-theft
|
||||
%patch106 -p1 -b .cve-2010-0656
|
||||
%patch108 -p1 -b .cve-2010-0648
|
||||
%patch109 -p1 -b .CVE-2010-1303_1304
|
||||
%patch110 -p1 -b .CVE-2010-1392
|
||||
%patch111 -p1 -b .CVE-2010-1396
|
||||
%patch112 -p1 -b .CVE-2010-1397
|
||||
%patch113 -p1 -b .CVE-2010-1398
|
||||
%patch114 -p1 -b .CVE-2010-1400
|
||||
%patch115 -p1 -b .CVE-2010-1412
|
||||
%patch116 -p1 -b .CVE-2010-1770
|
||||
%patch117 -p1 -b .CVE-2010-1773
|
||||
%patch118 -p1 -b .CVE-2010-1774
|
||||
%patch119 -p1 -b .CVE-2010-1119
|
||||
%patch120 -p1 -b .CVE-2010-1778
|
||||
|
||||
|
||||
# kde-qt branch
|
||||
%patch200 -p1 -b .kde-qt-patches-20090820git
|
||||
%patch201 -p0 -b .0118-qtcopy-define
|
||||
%patch202 -p0 -b .0283-do-not-deduce-scrollbar-extent-twice
|
||||
%patch203 -p0 -b .0285-qgv-dontshowchildren
|
||||
%patch201 -p1 -b .kde-qt-0001
|
||||
%patch202 -p1 -b .kde-qt-0002
|
||||
%patch203 -p1 -b .kde-qt-0003
|
||||
%patch204 -p1 -b .kde-qt-0004
|
||||
%patch205 -p1 -b .kde-qt-0005
|
||||
%patch206 -p1 -b .kde-qt-0006
|
||||
%patch207 -p1 -b .kde-qt-0007
|
||||
%patch212 -p1 -b .kde-qt-0012
|
||||
%patch217 -p1 -b .QT_GRAPHICSSYSTEM
|
||||
%patch218 -p1 -b .QTBUG-9793
|
||||
|
||||
# drop -fexceptions from $RPM_OPT_FLAGS
|
||||
RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's|-fexceptions||g'`
|
||||
# hack around (hopefully temporary) gcc borkage (#522576)
|
||||
#if 0%{?fedora} > 11
|
||||
#RPM_OPT_FLAGS="$RPM_OPT_FLAGS -fno-var-tracking-assignments"
|
||||
#endif
|
||||
|
||||
%define platform linux-g++
|
||||
%if "%{_qt4_datadir}" != "%{_qt4_prefix}" && "%{_lib}" == "lib64"
|
||||
|
||||
# some 64bit platforms assume -64 suffix, https://bugzilla.redhat.com/569542
|
||||
%if "%{?__isa_bits}" == "64"
|
||||
%define platform linux-g++-64
|
||||
%endif
|
||||
|
||||
# https://bugzilla.redhat.com/478481
|
||||
%ifarch x86_64
|
||||
%define platform linux-g++
|
||||
%endif
|
||||
|
||||
sed -i \
|
||||
-e "s|-O2|$RPM_OPT_FLAGS|g" \
|
||||
-e "s|g++.conf|g++-multilib.conf|g" mkspecs/%{platform}/qmake.conf
|
||||
|
@ -407,9 +527,6 @@ if [ "%{_lib}" == "lib64" ] ; then
|
|||
sed -i -e "s,/lib /usr/lib,/%{_lib} /usr/%{_lib},g" config.tests/{unix,x11}/*.test
|
||||
fi
|
||||
|
||||
# let syncqt to create new header
|
||||
rm -rf include
|
||||
|
||||
%build
|
||||
|
||||
# build shared, threaded (default) libraries
|
||||
|
@ -442,6 +559,7 @@ rm -rf include
|
|||
%{?phonon} %{!?phonon:-no-phonon} \
|
||||
%{?phonon_backend} \
|
||||
%{?no_pch} \
|
||||
-no-javascript-jit \
|
||||
-sm \
|
||||
-stl \
|
||||
-system-libmng \
|
||||
|
@ -467,6 +585,7 @@ rm -rf include
|
|||
%{?psql} \
|
||||
%{?odbc} \
|
||||
%{?sqlite} %{?_system_sqlite} \
|
||||
%{?tds} \
|
||||
%{!?docs:-nomake docs} \
|
||||
%{!?demos:-nomake demos} \
|
||||
%{!?examples:-nomake examples}
|
||||
|
@ -509,6 +628,15 @@ done
|
|||
|
||||
# nuke dangling reference(s) to %buildroot
|
||||
sed -i -e "/^QMAKE_PRL_BUILD_DIR/d" %{buildroot}%{_qt4_libdir}/*.prl
|
||||
sed -i -e "s|-L%{_builddir}/qt-everywhere-opensource-src-%{version}/lib||g" \
|
||||
%{buildroot}%{_qt4_libdir}/pkgconfig/*.pc
|
||||
|
||||
# nuke QMAKE_PRL_LIBS, seems similar to static linking and .la files (#520323)
|
||||
sed -i -e "s|^QMAKE_PRL_LIBS|#QMAKE_PRL_LIBS|" %{buildroot}%{_qt4_libdir}/*.prl
|
||||
|
||||
# .la files, die, die, die.
|
||||
rm -f %{buildroot}%{_qt4_libdir}/lib*.la
|
||||
|
||||
|
||||
%if 0
|
||||
#if "%{_qt4_docdir}" != "%{_qt4_prefix}/doc"
|
||||
|
@ -549,9 +677,6 @@ for lib in libQt*.a ; do
|
|||
done
|
||||
popd
|
||||
|
||||
# .la files, die, die, die.
|
||||
rm -f %{buildroot}%{_qt4_libdir}/lib*.la
|
||||
|
||||
%ifarch %{multilib_archs}
|
||||
# multilib: qconfig.h
|
||||
mv %{buildroot}%{_qt4_headerdir}/Qt/qconfig.h %{buildroot}%{_qt4_headerdir}/QtCore/qconfig-%{_arch}.h
|
||||
|
@ -579,9 +704,11 @@ install -p -m644 -D %{SOURCE4} %{buildroot}%{_qt4_sysconfdir}/Trolltech.conf
|
|||
# qt4-logo (generic) icons
|
||||
install -p -m644 -D %{SOURCE30} %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/qt4-logo.png
|
||||
install -p -m644 -D %{SOURCE31} %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/qt4-logo.png
|
||||
%if 0%{?docs}
|
||||
# assistant icons
|
||||
install -p -m644 -D tools/assistant/tools/assistant/images/assistant.png %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/assistant.png
|
||||
install -p -m644 -D tools/assistant/tools/assistant/images/assistant-128.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/assistant.png
|
||||
%endif
|
||||
# designer icons
|
||||
install -p -m644 -D tools/designer/src/designer/images/designer.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/designer.png
|
||||
# linguist icons
|
||||
|
@ -614,7 +741,7 @@ EOF
|
|||
mkdir -p %{buildroot}%{_sysconfdir}/rpm
|
||||
cat >%{buildroot}%{_sysconfdir}/rpm/macros.qt4<<EOF
|
||||
%%_qt4 %{name}
|
||||
%%_qt45 %{version}
|
||||
%%_qt46 %{version}
|
||||
%%_qt4_version %{version}
|
||||
%%_qt4_prefix %%{_libdir}/qt4
|
||||
%%_qt4_bindir %%{_qt4_prefix}/bin
|
||||
|
@ -630,17 +757,31 @@ cat >%{buildroot}%{_sysconfdir}/rpm/macros.qt4<<EOF
|
|||
%%_qt4_translationdir %%{_datadir}/qt4/translations
|
||||
EOF
|
||||
|
||||
# create/own %%_qt4_plugindir/styles
|
||||
# create/own stuff under %%_qt4_plugindir
|
||||
mkdir %{buildroot}%{_qt4_plugindir}/crypto
|
||||
mkdir %{buildroot}%{_qt4_plugindir}/gui_platform
|
||||
mkdir %{buildroot}%{_qt4_plugindir}/styles
|
||||
|
||||
%if 0%{?phonon:1}
|
||||
%if 0%{?phonon_internal}
|
||||
mkdir -p %{buildroot}%{_qt4_plugindir}/phonon_backend
|
||||
# needed by qtscriptgenerator
|
||||
pushd %{buildroot}%{_qt4_headerdir}
|
||||
ln -s phonon Phonon
|
||||
popd
|
||||
%else
|
||||
rm -fv %{buildroot}%{_qt4_libdir}/libphonon.so*
|
||||
rm -rfv %{buildroot}%{_libdir}/pkgconfig/phonon.pc
|
||||
# contents slightly different between phonon-4.3.1 and qt-4.5.0
|
||||
rm -fv %{buildroot}%{_includedir}/phonon/phononnamespace.h
|
||||
# contents dup'd but should remove just in case
|
||||
rm -fv %{buildroot}%{_includedir}/phonon/*.h
|
||||
rm -rfv %{buildroot}%{_qt4_headerdir}/phonon*
|
||||
#rm -rfv %{buildroot}%{_qt4_headerdir}/Qt/phonon*
|
||||
rm -fv %{buildroot}%{_datadir}/dbus-1/interfaces/org.kde.Phonon.AudioOutput.xml
|
||||
%endif
|
||||
|
||||
%if "%{?phonon_backend}" == "-phonon-backend"
|
||||
#if "%{?phonon_backend}" == "-phonon-backend"
|
||||
%if 0%{?phonon_backend_packaged}
|
||||
install -D -m 0644 %{SOURCE10} %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/phonon-gstreamer.svg
|
||||
install -D -m 0644 %{SOURCE11} %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/phonon-gstreamer.png
|
||||
install -D -m 0644 %{SOURCE12} %{buildroot}%{_datadir}/icons/hicolor/22x22/apps/phonon-gstreamer.png
|
||||
|
@ -648,8 +789,26 @@ install -D -m 0644 %{SOURCE13} %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/
|
|||
install -D -m 0644 %{SOURCE14} %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/phonon-gstreamer.png
|
||||
install -D -m 0644 %{SOURCE15} %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/phonon-gstreamer.png
|
||||
install -D -m 0644 %{SOURCE16} %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/phonon-gstreamer.png
|
||||
%else
|
||||
rm -fv %{buildroot}%{_qt4_plugindir}/phonon_backend/*_gstreamer.so
|
||||
rm -fv %{buildroot}%{_datadir}/kde4/services/phononbackends/gstreamer.desktop
|
||||
%endif
|
||||
|
||||
# remove qvfb translations, we don't ship qvfb
|
||||
rm -fv %{buildroot}%{_qt4_translationdir}/qvfb_*.qm
|
||||
|
||||
%find_lang qt --with-qt --without-mo
|
||||
|
||||
%find_lang assistant --with-qt --without-mo
|
||||
%find_lang assistant_adp --with-qt --without-mo
|
||||
%find_lang qt_help --with-qt --without-mo
|
||||
%find_lang qtconfig --with-qt --without-mo
|
||||
cat assistant.lang assistant_adp.lang qt_help.lang qtconfig.lang >qt-x11.lang
|
||||
|
||||
%find_lang designer --with-qt --without-mo
|
||||
%find_lang linguist --with-qt --without-mo
|
||||
cat designer.lang linguist.lang >qt-devel.lang
|
||||
|
||||
|
||||
%clean
|
||||
rm -rf %{buildroot}
|
||||
|
@ -685,7 +844,8 @@ touch --no-create %{_datadir}/icons/hicolor ||:
|
|||
gtk-update-icon-cache -q %{_datadir}/icons/hicolor 2> /dev/null ||:
|
||||
fi
|
||||
|
||||
%if "%{?phonon_backend}" == "-phonon-backend"
|
||||
#if "%{?phonon_backend}" == "-phonon-backend"
|
||||
%if 0%{?phonon_backend_packaged}
|
||||
%post -n phonon-backend-gstreamer
|
||||
touch --no-create %{_kde4_iconsdir}/hicolor &> /dev/null ||:
|
||||
|
||||
|
@ -705,9 +865,9 @@ fi
|
|||
%{_datadir}/icons/hicolor/*/apps/phonon-gstreamer.*
|
||||
%endif
|
||||
|
||||
%files
|
||||
%files -f qt.lang
|
||||
%defattr(-,root,root,-)
|
||||
%doc README README.kde-qt LGPL_EXCEPTION.txt LICENSE.LGPL LICENSE.GPL3
|
||||
%doc README LGPL_EXCEPTION.txt LICENSE.LGPL LICENSE.GPL3
|
||||
%if "%{_qt4_libdir}" != "%{_libdir}"
|
||||
/etc/ld.so.conf.d/*
|
||||
%dir %{_qt4_libdir}
|
||||
|
@ -732,24 +892,24 @@ fi
|
|||
%endif
|
||||
%config(noreplace) %{_qt4_sysconfdir}/Trolltech.conf
|
||||
%{_qt4_datadir}/phrasebooks/
|
||||
%{_qt4_libdir}/libQtCore.so.*
|
||||
%{_qt4_libdir}/libQtCore.so.4*
|
||||
%if 0%{?dbus:1}
|
||||
%if "%{_qt4_bindir}" != "%{_bindir}"
|
||||
%{_bindir}/qdbus
|
||||
%endif
|
||||
%{_qt4_bindir}/qdbus
|
||||
%{_qt4_libdir}/libQtDBus.so.*
|
||||
%{_qt4_libdir}/libQtDBus.so.4*
|
||||
%endif
|
||||
%{_qt4_libdir}/libQtNetwork.so.*
|
||||
%{_qt4_libdir}/libQtScript.so.*
|
||||
%{_qt4_libdir}/libQtSql.so.*
|
||||
%{_qt4_libdir}/libQtTest.so.*
|
||||
%{_qt4_libdir}/libQtXml.so.*
|
||||
%{_qt4_libdir}/libQtXmlPatterns.so.*
|
||||
%{_qt4_libdir}/libQtNetwork.so.4*
|
||||
%{_qt4_libdir}/libQtScript.so.4*
|
||||
%{_qt4_libdir}/libQtSql.so.4*
|
||||
%{_qt4_libdir}/libQtTest.so.4*
|
||||
%{_qt4_libdir}/libQtXml.so.4*
|
||||
%{_qt4_libdir}/libQtXmlPatterns.so.4*
|
||||
%dir %{_qt4_plugindir}
|
||||
%dir %{_qt4_plugindir}/sqldrivers/
|
||||
%{_qt4_plugindir}/sqldrivers/libqsqlite*
|
||||
%{_qt4_translationdir}/
|
||||
%dir %{_qt4_plugindir}/crypto/
|
||||
%dir %{_qt4_translationdir}/
|
||||
|
||||
%if 0%{?demos}
|
||||
%files demos
|
||||
|
@ -762,7 +922,7 @@ fi
|
|||
%{_qt4_demosdir}/
|
||||
%endif
|
||||
|
||||
%files devel
|
||||
%files devel -f qt-devel.lang
|
||||
%defattr(-,root,root,-)
|
||||
%{_qt4_bindir}/lconvert
|
||||
%{_qt4_bindir}/lrelease*
|
||||
|
@ -772,6 +932,7 @@ fi
|
|||
%{_qt4_bindir}/qdoc3*
|
||||
%{_qt4_bindir}/qmake*
|
||||
%{_qt4_bindir}/qt3to4
|
||||
%{_qt4_bindir}/qttracereplay
|
||||
%{_qt4_bindir}/rcc*
|
||||
%{_qt4_bindir}/uic*
|
||||
%{_qt4_bindir}/qcollectiongenerator
|
||||
|
@ -782,6 +943,7 @@ fi
|
|||
%{_qt4_bindir}/qhelpconverter
|
||||
%{_qt4_bindir}/qhelpgenerator
|
||||
%{_qt4_bindir}/xmlpatterns
|
||||
%{_qt4_bindir}/xmlpatternsvalidator
|
||||
%if "%{_qt4_bindir}" != "%{_bindir}"
|
||||
%{_bindir}/lconvert
|
||||
%{_bindir}/lrelease*
|
||||
|
@ -791,6 +953,7 @@ fi
|
|||
%{_bindir}/qdoc3
|
||||
%{_bindir}/qmake*
|
||||
%{_bindir}/qt3to4
|
||||
%{_bindir}/qttracereplay
|
||||
%{_bindir}/rcc*
|
||||
%{_bindir}/uic*
|
||||
%{_bindir}/designer*
|
||||
|
@ -803,6 +966,7 @@ fi
|
|||
%{_bindir}/qhelpconverter
|
||||
%{_bindir}/qhelpgenerator
|
||||
%{_bindir}/xmlpatterns
|
||||
%{_bindir}/xmlpatternsvalidator
|
||||
%endif
|
||||
%if "%{_qt4_headerdir}" != "%{_includedir}"
|
||||
%dir %{_qt4_headerdir}/
|
||||
|
@ -815,6 +979,8 @@ fi
|
|||
%{_qt4_datadir}/q3porting.xml
|
||||
%if 0%{?phonon:1}
|
||||
%{_qt4_libdir}/libphonon.prl
|
||||
%endif
|
||||
%if 0%{?phonon_internal}
|
||||
%{_qt4_libdir}/libphonon.so
|
||||
%endif
|
||||
%{_qt4_libdir}/libQt*.so
|
||||
|
@ -870,28 +1036,43 @@ fi
|
|||
%{_qt4_plugindir}/sqldrivers/libqsqlpsql*
|
||||
%endif
|
||||
|
||||
%files x11
|
||||
%if "%{?sqlite}" == "-plugin-sql-sqlite"
|
||||
%files sqlite
|
||||
%defattr(-,root,root,-)
|
||||
%{_qt4_plugindir}/sqldrivers/libqsqlite*
|
||||
%endif
|
||||
|
||||
%if "%{?tds}" == "-plugin-sql-tds"
|
||||
%files tds
|
||||
%defattr(-,root,root,-)
|
||||
%{_qt4_plugindir}/sqldrivers/libqsqltds*
|
||||
%endif
|
||||
|
||||
%files x11 -f qt-x11.lang
|
||||
%defattr(-,root,root,-)
|
||||
%{_sysconfdir}/rpm/macros.*
|
||||
%if 0%{?phonon:1}
|
||||
%if 0%{?phonon_internal}
|
||||
%{_qt4_libdir}/libphonon.so.4*
|
||||
%dir %{_datadir}/kde4/services/phononbackends/
|
||||
%{_datadir}/dbus-1/interfaces/org.kde.Phonon.AudioOutput.xml
|
||||
%endif
|
||||
%{_qt4_libdir}/libQt3Support.so.*
|
||||
%{_qt4_libdir}/libQtAssistantClient.so.*
|
||||
%{_qt4_libdir}/libQtCLucene.so.*
|
||||
%{_qt4_libdir}/libQtDesigner.so.*
|
||||
%{_qt4_libdir}/libQtDesignerComponents.so.*
|
||||
%{_qt4_libdir}/libQtGui.so.*
|
||||
%{_qt4_libdir}/libQtHelp.so.*
|
||||
%{_qt4_libdir}/libQtOpenGL.so.*
|
||||
%{_qt4_libdir}/libQtScriptTools.so.*
|
||||
%{_qt4_libdir}/libQtSvg.so.*
|
||||
%{?webkit:%{_qt4_libdir}/libQtWebKit.so.*}
|
||||
%{_qt4_libdir}/libQt3Support.so.4*
|
||||
%{_qt4_libdir}/libQtAssistantClient.so.4*
|
||||
%{_qt4_libdir}/libQtCLucene.so.4*
|
||||
%{_qt4_libdir}/libQtDesigner.so.4*
|
||||
%{_qt4_libdir}/libQtDesignerComponents.so.4*
|
||||
%{_qt4_libdir}/libQtGui.so.4*
|
||||
%{_qt4_libdir}/libQtHelp.so.4*
|
||||
%{_qt4_libdir}/libQtMultimedia.so.4*
|
||||
%{_qt4_libdir}/libQtOpenGL.so.4*
|
||||
%{_qt4_libdir}/libQtScriptTools.so.4*
|
||||
%{_qt4_libdir}/libQtSvg.so.4*
|
||||
%{?webkit:%{_qt4_libdir}/libQtWebKit.so.4*}
|
||||
%{_qt4_plugindir}/*
|
||||
%exclude %{_qt4_plugindir}/crypto
|
||||
%exclude %{_qt4_plugindir}/sqldrivers
|
||||
%if "%{?phonon_backend}" == "-phonon-backend"
|
||||
#if "%{?phonon_backend}" == "-phonon-backend"
|
||||
%if 0%{?phonon_backend_packaged}
|
||||
%exclude %{_qt4_plugindir}/phonon_backend/*_gstreamer.so
|
||||
%endif
|
||||
%if "%{_qt4_bindir}" != "%{_bindir}"
|
||||
|
@ -905,7 +1086,172 @@ fi
|
|||
%{_datadir}/applications/*qtconfig.desktop
|
||||
%{_datadir}/icons/hicolor/*/apps/qt4-logo.*
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Sep 30 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.3-9
|
||||
- Wrong Cursor when widget become native on X11 (QTBUG-6185)
|
||||
|
||||
* Tue Jul 01 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.3-8
|
||||
- use find_lang to package the qm files (#609749)
|
||||
- put the qm files into the correct subpackages
|
||||
- remove qvfb translations, we don't ship qvfb
|
||||
|
||||
* Tue Jun 29 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.3-7
|
||||
- workaround glib_eventloop crasher induced by gdal/grass (bug #498111)
|
||||
|
||||
* Fri Jun 20 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.3-5
|
||||
- avoid timestamps in uic-generated files to be multilib-friendly
|
||||
|
||||
* Fri Jun 18 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.3-4
|
||||
- QtWebKit does not search correct plugin path(s) (#568860)
|
||||
- QtWebKit browsers crash with flash-plugin (rh#605677,webkit#40567)
|
||||
|
||||
* Tue Jun 15 2010 Jaroslav Reznik <jreznik@redhat.com> - 4.6.3-3
|
||||
- WebKit security update:
|
||||
CVE-2010-1119, CVE-2010-1400, CVE-2010-1778
|
||||
|
||||
* Fri Jun 11 2010 Jaroslav Reznik <jreznik@redhat.com> - 4.6.3-2
|
||||
- WebKit security update:
|
||||
CVE-2010-1303_1304, CVE-2010-1392, CVE-2010-1396, CVE-2010-1397,
|
||||
CVE-2010-1398, CVE-2010-1412, CVE-2010-1770,
|
||||
CVE-2010-1773, CVE-2010-1774
|
||||
|
||||
* Tue Jun 08 2010 Than Ngo <than@redhat.com> - 4.6.3-1
|
||||
- 4.6.3
|
||||
|
||||
* Thu May 27 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-20
|
||||
- Unsafe use of rand() in X11 (QTBUG-9793)
|
||||
|
||||
* Mon May 17 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-19
|
||||
- support QT_GRAPHICSSYSTEM env
|
||||
|
||||
* Thu May 06 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-18
|
||||
- +Provides: qt4-webkit(-devel)
|
||||
|
||||
* Thu May 06 2010 Than Ngo <than@redhat.com> - 4.6.2-17
|
||||
- bz#589169, fix multiple flaws in webkit
|
||||
CVE-2010-0047, CVE-2010-0648, CVE-2010-0656
|
||||
|
||||
* Thu Apr 29 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.2-16
|
||||
- restore qt-everywhere-opensource-src-4.6.2-cups.patch (#586725)
|
||||
|
||||
* Wed Apr 28 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-15
|
||||
- own %%{_qt4_plugindir}/crypto
|
||||
|
||||
* Thu Apr 15 2010 Than Ngo <than@redhat.com> - 4.6.2-14
|
||||
- backport from 4.7 branch to get the printDialog to check
|
||||
for default paperSize via CUPS, it replaces the patch
|
||||
qt-everywhere-opensource-src-4.6.2-cups.patch
|
||||
|
||||
* Tue Apr 06 2010 Than Ngo <than@redhat.com> - 4.6.2-13
|
||||
- backport from 4.7 branch to fix s390(x) atomic ops crashes
|
||||
|
||||
* Fri Apr 02 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-12
|
||||
- Associate text/vnd.trolltech.linguist with linguist (#579082)
|
||||
|
||||
* Tue Mar 23 2010 Tom "spot" Callaway <tcallawa@redhat.com> - 4.6.2-11
|
||||
- fix type cast issue on sparc64
|
||||
- drop "recreate .qm file", it's not needed anymore
|
||||
|
||||
* Tue Mar 23 2010 Than Ngo <than@redhat.com> - 4.6.2-10
|
||||
- fix type cast issue on s390x
|
||||
|
||||
* Mon Mar 22 2010 Than Ngo <than@redhat.com> - 4.6.2-9
|
||||
- backport patch to fix a crash when reparenting an item
|
||||
in QGraphicsView, QTBUG-6932
|
||||
- drop dangling reference(s) to %%buildroot in *.pc
|
||||
|
||||
* Wed Mar 17 2010 Jaroslav Reznik <jreznik@redhat.com> - 4.6.2-8
|
||||
- WebKit security update:
|
||||
CVE-2010-0046, CVE-2010-0049, CVE-2010-0050, CVE-2010-0051,
|
||||
CVE-2010-0052, CVE-2010-0054
|
||||
|
||||
* Sat Mar 13 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.2-7
|
||||
- BR alsa-lib-devel (for QtMultimedia)
|
||||
|
||||
* Sat Mar 13 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.2-6
|
||||
- Provides: qt-assistant-adp(-devel)
|
||||
|
||||
* Fri Mar 05 2010 Than Ngo <than@redhat.com> - 4.6.2-5
|
||||
- Make tablet detection work with new wacom drivers (#569132)
|
||||
|
||||
* Mon Mar 01 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-4
|
||||
- fix 64bit platform logic, use linux-g++-64 everywhere except x86_64 (#569542)
|
||||
|
||||
* Sun Feb 28 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.2-3
|
||||
- fix CUPS patch not to crash if currentPPD is NULL (#566304)
|
||||
|
||||
* Tue Feb 16 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-2
|
||||
- macros.qt4: s/qt45/qt46/
|
||||
|
||||
* Mon Feb 15 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.2-1
|
||||
- 4.6.2
|
||||
|
||||
* Fri Feb 05 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.1-3
|
||||
- improve cups support (#523846, kde#180051#c22)
|
||||
|
||||
* Tue Jan 19 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.1-2
|
||||
- drop bitmap_font_speed patch, rejected upstream
|
||||
|
||||
* Tue Jan 19 2010 Than Ngo <than@redhat.com> - 4.6.1-1
|
||||
- 4.6.1
|
||||
|
||||
* Mon Jan 11 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-5
|
||||
- bitmap_font_speed patch (QTBUG-7255)
|
||||
|
||||
* Sat Jan 09 2010 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-4
|
||||
- Fix crash when QGraphicsItem destructor deletes other QGraphicsItem (kde-qt cec34b01)
|
||||
- Fix a crash in KDE/Plasma with QGraphicsView. TopLevel list of items (kde-qt 63839f0c)
|
||||
|
||||
* Wed Dec 23 2009 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.0-3
|
||||
- disable QtWebKit JavaScript JIT again, incompatible with SELinux (#549994)
|
||||
|
||||
* Sat Dec 05 2009 Kevin Kofler <Kevin@tigcc.ticalc.org> - 4.6.0-2
|
||||
- own %%{_qt4_plugindir}/gui_platform
|
||||
|
||||
* Tue Dec 01 2009 Than Ngo <than@redhat.com> - 4.6.0-1
|
||||
- 4.6.0
|
||||
|
||||
* Tue Nov 17 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-0.6.rc1
|
||||
- qt-4.6.0-rc1
|
||||
|
||||
* Sat Nov 14 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-0.5.beta1
|
||||
- -tds: Add package with TDS sqldriver (#537586)
|
||||
- add arch'd provides for sql drivers
|
||||
|
||||
* Sun Nov 08 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-0.4.beta1
|
||||
- -x11: Requires: %%{name}-sqlite%{?_isa}
|
||||
|
||||
* Mon Oct 26 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-0.3.beta1
|
||||
- kde-qt patches (as of 20091026)
|
||||
|
||||
* Fri Oct 16 2009 Than Ngo <than@redhat.com> - 4.6.0-0.2.beta1
|
||||
- subpackage sqlite plugin, add Require on qt-sqlite in qt-x11
|
||||
for assistant
|
||||
- build/install qdoc3 again
|
||||
|
||||
* Wed Oct 14 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.6.0-0.1.beta1
|
||||
- qt-4.6.0-beta1
|
||||
- no kde-qt patches (yet)
|
||||
|
||||
* Sat Oct 10 2009 Than Ngo <than@redhat.com> - 4.5.3-4
|
||||
- fix translation build issue
|
||||
- rhel cleanup
|
||||
|
||||
* Tue Oct 06 2009 Jaroslav Reznik <jreznik@redhat.com> - 4.5.3-3
|
||||
- disable JavaScriptCore JIT, SE Linux crashes (#527079)
|
||||
|
||||
* Fri Oct 02 2009 Than Ngo <than@redhat.com> - 4.5.3-2
|
||||
- cleanup patches
|
||||
- if ! phonon_internal, exclude more/all phonon headers
|
||||
- qt-devel must Requires: phonon-devel (#520323)
|
||||
|
||||
* Thu Oct 01 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.3-1
|
||||
- qt-4.5.3
|
||||
|
||||
* Tue Sep 29 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.2-21
|
||||
- switch to external/kde phonon
|
||||
|
||||
* Mon Sep 28 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.2-20
|
||||
- use internal Qt Assistant/Designer icons
|
||||
- -devel: move designer.qch,linguist.qch here
|
||||
|
|
2
sources
2
sources
|
@ -1,10 +1,10 @@
|
|||
d9f511e4b51983b4e10eb58b320416d5 hi128-app-qt4-logo.png
|
||||
6dcc0672ff9e60a6b83f95c5f42bec5b hi48-app-qt4-logo.png
|
||||
8e3924f417fea67f72b2105faed2119c gstreamer-logo.svg
|
||||
28a7e8ac9805a6f614d2a27ee1a6ac9d qt-x11-opensource-src-4.5.2.tar.bz2
|
||||
60de9d7e1cddd019f09fd036f0e5413a hi128-phonon-gstreamer.png
|
||||
7ca265e0cf75b3b4c81e1490d3dba3be hi16-phonon-gstreamer.png
|
||||
0a9f69d901aded140d4fed969c22e14f hi22-phonon-gstreamer.png
|
||||
12db12c009b722a6dc141f78feb7e330 hi32-phonon-gstreamer.png
|
||||
86c34a1b81d44980b1381f94ed6b7a23 hi48-phonon-gstreamer.png
|
||||
153505c71ec021b0a3bd4b74f2492e93 hi64-phonon-gstreamer.png
|
||||
5c69f16d452b0bb3d44bc3c10556c072 qt-everywhere-opensource-src-4.6.3.tar.gz
|
||||
|
|
Loading…
Reference in New Issue