summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fixed a bug where spans across empty cells got broken.Jan Arve Saether2013-04-042-1/+29
| | | | | | | | | | | | | | | | If a row/column is only used only because of the spanning of an item, the cell should be treated as it didn't exist. We keep track of this with the "ignore" bit array. The old code would always start from the row/column at position 1. In the attached testcase this made the effectiveRowSpan become larger than actually needed. Task-number: QTBUG-30255 Change-Id: Ief0e7018ee8e5ee36272ce075a43312ffeac7b91 (cherry picked from qtbase/f9e43c526a30ae3912adfe3d5cb781af5ddda4b0) Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Adding transformed support for QNX QWS pluginKarim Pinter2013-04-044-12/+70
| | | | | | | | | | | It implements the setDirty function which is called by the transformed plugin when the screen is rotated. The rotated image is in the surface memory, just the bliting is done here. Task-number: QTBUG-29949 Change-Id: I0be2d037d6e1ef85106175aa47cc548b99b05a94 Reviewed-by: Pasi Petäjäjärvi <pasi.petajajarvi@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* BlackBerry: Added warning when low memory event is receivedBernd Weimer2013-04-031-0/+6
| | | | | | | | Low memory warning has been added for debug purposes. Backport of 6b413dc32c485853710352a95e8bef928682558a Change-Id: I79b3815d314227634b739935d85248cc526f2c89 Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
* BlackBerry: show dialogs full screenRafael Roquetto2013-04-021-0/+8
| | | | | | | | | | | | Except for message box, which will have their optimal geometry calculated at runtime. This fix is not necessary on Qt5 Change-Id: Ida4743acdceb5424ab93aa3a32c78db61dd6795c Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com> Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Fixed some declarative auto testsBernd Weimer2013-03-283-49/+49
| | | | | | | This is a backport from qt5/qtquick1 (commit aad8f0b) Change-Id: Ia3eacce5ccd50827526203a9992ddef81a9f0c41 Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* Windows: Fix the last file dialog bottleneck.Sergio Martins2013-03-284-4/+11
| | | | | | | | | | | | | | | | | | | Went from taking 30 seconds to 2 seconds, on a SDCard with 10k files. Windows file dialog does not resolve NTFS symlinks, it just shows an empty icon, and the link name, not the target. This allows for a big performance gain by reducing the number of calls to GetFileAttributesEx() by checking the extension directly. This also fixes the problems with the native file dialog, which for some reason, is creating a QFileSystemModel too. Task-number: QTBUG-13182 (cherry picked from commit 51f00deffac49c4277425837f0132b0c721bb689) Change-Id: If7bd63d68e1870c5e48907ae79f4c4bdc6972b00 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Windows: Fix one of the two file dialog bottlenecks.Sergio Martins2013-03-281-1/+14
| | | | | | | | | | | | | | This patch reduces the number of calls to GetFileAttributesEx() when icon lookup is being done. The second bottleneck is a couple of isSymLink() calls. Will fix that next. Task-number: QTBUG-13182 (cherry picked from commit a7f6f32fadd5024697c16dfcbc07d6d11beb45fa) Change-Id: If42b791d22fe0429a3b43992bad037afad09c448 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* QMdi: Don't emit subWindowActivated during StyleChange handling.David Faure2013-03-282-1/+41
| | | | | | | | | | | | | | | The handling of StyleChange de-maximizes the child window temporarily, which was emitting subWindowActivated. This would crash lokalize, because deactivating a window means deleting the widgets associated with it, and style-change handling is done in QApplication by looping over QApplication::allWidgets, which would then contain dangling pointers. Full valgrind log at https://bugs.kde.org/show_bug.cgi?id=271494#c7 Change-Id: I256da214bf00fd7925dcee67b4f0414e57fc453b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> (cherry picked from qtbase/a6e5ccbe223c5a606e15556e8708e863442d9f72)
* Backport some enum optimizations from Qt 5Alan Alpert2013-03-271-11/+33
| | | | | | | | | | | (backport of 108b9bbe2ff2f5f31525408a08d248499d95a49f in qtquick1) Saving the int when we check the enum is valid allows us to make it a literal assignment instead of a binding, which is much faster on object creation. Change-Id: Ieb174289438a17574c4716df372b04d4dee6d0db Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
* QNonContiguousByteDevice: roll back complete internal state in reset()Peter Hartmann2013-03-261-0/+6
| | | | | | | | | ... otherwise we would not start reading from the beginning when the device was reset. Change-Id: I897adbad6e1f240fa871758ec7e3d6b499cb5944 (cherry-picked from commit ffe45f1896adfff93258b917f6a566dcc06a6597) Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* SSL code: store SSL parameters for debugging, guarded by definePeter Hartmann2013-03-251-0/+35
| | | | | | | | | | | | | ... so SSL traffic can be decrypted with e.g. tcpdump / Wireshark. For this to work, the define needs to be uncommented and QtNetwork recompiled. This will create a file in /tmp/qt-ssl-keys which can be fed into Wireshark. A recent version of Wireshark is needed for this to work. (cherry-picked from commit 1f180e9690a0a5f6cc849c1988ccda13de1b1e20) Change-Id: I413ffd2494c780f92ccad7e4fdc11b790966e7ce Reviewed-by: Richard J. Moore <rich@kde.org>
* Fix Mac OS X crc/dwarf2 test for non-default Xcode setup.Danny Boelens2013-03-223-6/+38
| | | | | | | | | | | | | | | | | The crc.test and dwarf2.test scripts are now using the SDK and arch settings passed to it. If you install Xcode without the "UNIX Development" option, this is essential to let the compiler find standard headers and let the test program compile successfully. In addition, let configure pass the SDK and arch settings given on the command line to the scripts. These scripts are no longer present in Qt 5. Change-Id: I78c0b3594b91827a6618a9a152949e9201ca64c8 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
* QWindowsVistaStyle::drawPrimitive(PE_Frame): fix background clippingJ-P Nurmi2013-03-211-10/+7
| | | | | | | | | | | | | | | The purpose of PE_Frame is to draw the frame, not the background. The old code tried to check whether a custom base brush was set, and otherwise let the theme draw the background. That didn't work together with CSS background images. This change removes the background drawing from PE_Frame, and let's PE_Widget to draw the background using the base brush that defaults to a color fetched from the theme. Task-number: QTBUG-24783 (cherry picked from qtbase/f1e681bed21e131864fe1e1c91679f7a56b06823) Change-Id: Ief256d1d5861abc95dedf0b5d0a4f8e338c48941 Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* mkspecs: fix the path for rcc for win32-g++Liang Qi2013-03-201-0/+1
| | | | | | | | patch not needed for Qt5 Task-number: QTBUG-27237 Change-Id: I41856f55b71661bfa01c4011129a35e110a234f9 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Make QPixmap::grabWindow work on retina displays.Morten Johan Sørvig2013-03-201-1/+4
| | | | | | | Scale by qt_mac_get_scalefactor. Change-Id: I94cd4e0b2f81f7a83f14ff018e772dad1da10284 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Use [NSScreen backingScaleFactor] on 10.7+Morten Johan Sørvig2013-03-201-2/+7
| | | | | | | userSpaceScaleFactor is deprecated. Change-Id: I892cb579e4b3ef9226495759c884d0e74c85a1d6 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Fixed QPainter::drawPolyline() not drawing solid lines.Samuel Rødal2013-03-201-1/+16
| | | | | | | | | | If a line segment isn't filled we keep using the same point of origin. Task-number: QTBUG-26156 Change-Id: I20af8410a7039b69848f201ab62fd3c01b95531b Reviewed-by: Titta Heikkala <titta.heikkala@digia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com> (cherry picked from commit b528e1324add2208abf8f83fb51a8bd2183157f5)
* Fixed artifacts when drawing same line with different clips.Samuel Rødal2013-03-202-17/+53
| | | | | | | | | | | Expanding on the change fixing QTBUG-24762 with the realization that any line needs to be drawn in a consistent way regardless of system or painter clip, not just dashed lines. Task-number: QTBUG-25036 Change-Id: Ief7ef19cc92c52e7d792500a581a072ba032767e Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com> (cherry picked from commit c7191d3e214b9cdb17ec383b61f7e21e784f80d0)
* Inital port of QSystemLocale on BlackBerry 10El Mehdi Fekari2013-03-205-107/+422
| | | | | | | | Backport of: a0c4a712263dbacd2c8d95da64e00bd213d05cbf Change-Id: I4253067b42a8aa93325d48eeaa3a9937be2d2b75 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* Fixed bug in QTimeLine::setPaused(false)Jan Arve Saether2013-03-202-0/+26
| | | | | | | | | | | | | The problem was that the elapsed timer was not restarted, causing the currentTime() not being adjusted for the time it was paused. (cherry-picked from Qt 5: 75614792fa2370b6b0402117bf) Task-number: QTBUG-30108 Change-Id: I9718aa408075623514717328321c34e7ab3af436 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* Tests: stabilize tst_QDockWidget on small screensJ-P Nurmi2013-03-201-1/+1
| | | | | | | | | | | | | The test has been recently failing in CI. The problem was easy to reproduce in a virtual machine by resizing the window of the virtual machine small enough. This change makes sure that the requested size hint is significantly smaller than the desktop size, to avoid the window manager stepping in and limiting the window size. Change-Id: Id8ce63b2b88cbed964e0330633c5d2e1dc33598c Reviewed-by: Caroline Chao <caroline.chao@digia.com> (cherry picked from commit 36e6632fa363152e1a0d42e53a0e5ada09092324) Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* Reorder for performance reasons.Sérgio Martins2013-03-192-2/+2
| | | | | | | | | isSymLink() can be expensive in a few cases. Change-Id: Ib8b9f0c13d7ce141a539a4729be81d9faa4382ea Reviewed-by: David Faure (KDE) <faure@kde.org> (cherry picked from commit 1975e65d73ef2bf225bd765e6b50b6f50167f71c) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Improve emission of FocusScope focusChanged signals.Andrew den Exter2013-03-195-31/+584
| | | | | | | | | | | | | | | | | | | | | | | Emit activeFocusChanged up the focus tree when an item receives a focus event, rather than when the focusItem changes which happens before internal state is sufficiently updated for hasFocus and hasActiveFocus to return the correct values from within a changed signal handler. There are some limitions to this. First the signals are not emitted reliably when the scene is not active which makes sense for activeFocus but not for focus. The second is in some instances the focus and activeFocus can update unnecessarily while the focus chain sorts itself out. QDeclarativeItem tests by Andreas Aardal Hanssen <andreas@hanssen.name> Task-number: QTBUG-28288 Task-number: QTBUG-25644 (cherry picked from qtquick1/c520a69f06317fb90d37324bf284ef9614cb5dbf) Change-Id: Iac12bf8c95cbf3525b454f4afca06a54a5c14b4e Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name> Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* QThread::isFinished should return true from finished()Olivier Goffart2013-03-192-2/+37
| | | | | | | | | | | | | | | | | | | | | | and isRunning() should return false. This restore the Qt 4.7 behaviour In Qt 4.7, the finished() was called with the thread's intenal mutex locked. Which mean that: - Call to isRunning or isFinished called from a slot connected to finish within the thread would deadlock. (Hence no compatibility to keep here) - Call to isRunning or isFinished from a slot connected with QueuedConnection in another thread would lock the mutex until the destructors are finished. and then return as if the thread have finished. Change-Id: I963eccae8f7634aff90cc4bbab6ca886a78e35eb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry-picked from qtbase commit ec5e59b73c20a7dc6aec96c829f1e53c3fa58c07) Task-number: QTBUG-30251 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* WebKit: Fix using macro to determine Mac user agent architectureJonathan Liu2013-03-181-1/+1
| | | | | | | | | | | | Using || operator with #ifdef is incorrect. As a result, the architecture for the user agent is incorrectly set to PPC on an Intel Mac. This is a partial backport of r128775 in WebKit upstream. Task-number: QTBUG-30187 Change-Id: I6842f113fd024ababaf67e76dfee8f93e0988d08 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Remove the usage of undefined QFontDatabase::WritingSystemLiang Qi2013-03-161-8/+0
| | | | | | | | | There is no definition for Yi, Tagalog...Braille in QFontDatabase::WritingSystem, see the header file. (cherry picked from commit qtbase b7b858595e6e2d8dcc9debeb45eb8b9b294b9be6) Change-Id: I0d3625c58310d9af680799d20867f04b42845ca9 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Clear the alphaCache when starting new paintingAndy Shaw2013-03-141-1/+1
| | | | | | | | | The alpha cache needs to be cleared when starting a new paint otherwise it will assume that some elements already exist in the PDF when they don't. Change-Id: I97451c53c0c99b80a25a057735cef7b3bb830a7a Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Fixes: assert in QPainter::fillRect on very large paint devicesaavit2013-03-141-0/+2
| | | | | | | | | | For devices taller than 32768, fillRect with linear gradient would go below the cliprect. Task-number: QTBUG-26766 Change-Id: I516ede1545909e9ce2de5812c61bb473f99f5759 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com> (cherry picked from qtbase/db775741ed57efc16c697471f5b87689df7105a8)
* Fixed dashes being rendered differently depending on system clip.Samuel Rødal2013-03-145-18/+63
| | | | | | | | | | | | We need to clip lines to the unclipped device rect in the case of dashing, since otherwise the dashes will be shifted and rendered differently when partial repaints are done. Task-number: QTBUG-24762 Change-Id: I3599b54baa552acc20bf8cc2e12f846b45f6019e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com> (cherry picked from commit a12f6ba302e54c1570c54aa4c722f2dafbf794af)
* Update Irish locale to return correct date formatEl Mehdi Fekari2013-03-133-3/+35
| | | | | Change-Id: I89ad9b97dba6f76d34a23ec03b119fb51e592917 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Fixed QTreeWidgetIterator to work with sorted QTreeWidgetJan Arve Saether2013-03-132-5/+31
| | | | | | | | | | | | | We cannot access children directly, since that won't ensure that the pending sort is executed. However, the functions we need are there already and actually makes the code nicer. Task-number: QTBUG-29903 Change-Id: I6899284275dd79b991896a5f08486b58d95f819d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com> (cherry picked from qtbase/aa2d10750ad8cdb6a86d519063664c2924b2a635) Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Workaround a bug in mktime on QNXFabian Bumberger2013-03-131-0/+10
| | | | | | | | | | | | | Under certain circumstances, mktime failes to convert the tm struct into secs since epoch. This is a workaround and fixes the qdatetime and qqmllocale autotests. Backport of: 56820382f26 Change-Id: I7d819aad2d6901cd096b441f2c18fd97108d9abb Reviewed-by: Mehdi Fekari <mfekari@rim.com> Reviewed-by: Wolfgang Bremer <wbremer@blackberry.com> Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Updated WebKit to 5fc7dcbe084a8ee8beda11b92dc2111be1285434Simon Hausmann2013-03-135-3/+38
| | | | | | | | | This brings in a fix for QTBUG-30081 as well as a backport of https://bugs.webkit.org/show_bug.cgi?id=103529 Change-Id: Ibcebe76d6999dc304d4c0323bbfa44be93909285 Reviewed-by: Jonathan Liu <net147@gmail.com> Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* List supported file formats in search indexing.Leonard Lee2013-03-131-0/+3
| | | | | | | | | | | The supported file formats is implemented in QHelpSearchIndexWriter::indexableFiles() function. Task-number: QTBUG-30110 Change-Id: I3a0885f4c85ec7e14c5f0d4edbb33a463f657b54 (cherry picked from commit qttools/24f92f79e5d1198e79f4d46489af35999e8e74cf) Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Fix warnings in tests (CLANG).Friedemann Kleint2013-03-113-4/+3
| | | | | | | | | - Statement has no effect - Adding int to string - Unspecified behavior when comparing character literals. Change-Id: Ie9cb9a1036b5cf5c62890685c60dee4af1ce7148 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Add WindowStateChanged eventRafael Roquetto2013-03-065-0/+37
| | | | | | | | | | Not currently considering activation state. backport from qt5 8dc2f81c9f0e6eb8cab09e5d682358fd140b49b8 Change-Id: Ib46e554b08cc8d15f83e9865a8f0be3f8d7b9d16 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix moving widgets in horizontal layouts in RTL mode.Friedemann Kleint2013-03-061-1/+4
| | | | | | | | Task-number: QTBUG-25872 Change-Id: Ia311b88f0ed3450d798bc5a9136e978c642d5b25 Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com> (cherry picked from qttools/eb456f72052b02a77e22868bfa55a25d7af3e660)
* BlackBerry: handle window state navigator eventsRafael Roquetto2013-03-056-7/+75
| | | | | | | | backport of qt5 439002cddeb32766ea9806ac8b5cf9a973ed0f13 Change-Id: I2431ebd1240ba6f3c2b690b311301d222ec10865 Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Active X plugin: Fix setting a control by task menu.Friedemann Kleint2013-03-051-2/+3
| | | | | | | | | | | | | | The property is a QString when set by the menu or a PropertySheetStringValue when loading the form. Breakage introduced by 8695c1753964eeb06b5d9306010b56be5fc151c0 . Task-number: QTBUG-29234 Change-Id: I84c3de80b99c8a20aaf1f8f7289882b0092d6a0a Reviewed-by: Andy Shaw <andy.shaw@digia.com> (cherry picked from qttools/3e43b158ce158dc1285593d2c7555351033fc3ce)
* QSslConfiguration: toggle on demand loading of root certs properlyPeter Hartmann2013-03-046-6/+90
| | | | | | | | | | | | | | | | | make sure we keep track of when we can load root certs and when we cannot (we cannot when the developer set the certs explicitly). This is implemented the same way for QSslSocket already, and needs to be duplicated because we have 2 methods for setting CA certificates: one in QSslSocket and one in QSslConfiguration. In addition, adapt the auto test which checks whether setting a default QSslConfiguration works: There is no way to set on demand loading through the API, so it should be enabled by default. Task-number: QTBUG-29103 (backport of commit ce35c0db0d9dd849c736eabaeb57d597186aaa13) Change-Id: Idf15c21092c7727e1080b1c261ce055f30dbcf63 Reviewed-by: Richard J. Moore <rich@kde.org>
* unmess CONFIG/QT_CONFIG static/sharedOswald Buddenhagen2013-03-012-4/+9
| | | | | | | | | | | | | | | bring it to the state of 5.0.2: both QT_CONFIG and CONFIG in qconfig.pri contain the respective flag, so it is a) visible how qt was built and b) user code has a consistent default. before, on windows we had it only in qconfig.pri's CONFIG (so it was harder to find the qt config), and on unix we had it only in .qmake.cache's CONFIG (so it was impossible to find the qt config in a clean way, and there was no default (other than some arbitrary mess inside qmake itself)). Change-Id: Iad06de8c4435cec3e1407babde037ac96cb5bf66 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* define NDEBUG in MSVC/nmake release buildsJoerg Bornemann2013-03-011-0/+5
| | | | | | | | | | | Some headers, like assert.h, check for the presence of NDEBUG. We already define NDEBUG for MSVC/vcproj release builds. Task-number: QTBUG-3389 Change-Id: I3b1510d47ff80611aa8072e66492ff2d648393eb Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> (cherry picked from commit ebc4fb452ac268657023cb957c1b0ca0e315b9fc)
* Fix generation of XCode projects for XCode 4.6Andy Shaw2013-03-011-3/+5
| | | | | | | | | | | | When a framework is referenced in the XCode project then it is known as a framework by the lastKnownFileType and not the reference type. This ensures it works in both XCode 3 and XCode 4. Task-number: QTBUG-29371 Change-Id: I434246a46d6c5bfd50ba7de1a7c710c0caf0bc0a Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com> (cherry picked from qtbase/4a6a066df2f104763c35eaaaf8dc7b1366d483b2)
* Introduce compileTest function.Oswald Buddenhagen2013-03-012-103/+116
| | | | | | | | | | | | This avoids the enormous duplication of identical command line arguments passed down to compile.test. This necessitates the addition of a -config parameter to compile.test, as QMAKE_CONFIG needs to be extended in some cases. Backport of qtbase commit ca4823505bee3674a8d65cd1bdd45ea93546114b. Change-Id: I22aa0336443d330e49e674e5484f08c43c913d31 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Fix CreateFileMapping() error handlingPeter Kümmel2013-03-012-4/+5
| | | | | | | | | | | CreateFileMapping() returns NULL in case of an error. The patch corrects the wrong testing on INVALID_HANDLE_VALUE, and sets NULL for invalid handles. Change-Id: Iaab4945ed88ee92bbf9a0871e95a5820dd1a56ed (cherry-picked from qtbase/1a8f67938c4146614fec3788c7868dc1a314cc84) Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Add support for SQLSTATE error codesAndras Mantia2013-02-281-12/+18
| | | | | | | | | | | | | | | Postgres can report detailed information about an error using error codes. See http://www.postgresql.org/docs/8.1/static/errcodes-appendix.html . The current driver doesn't report the error, nor is it supported by the QSqlError object. The patch appends the error to the error message, helping applications to: - handle different errors in a specific way - show correct, translated error messages, independently on the language of the postgres installation Change-Id: I5c7792606307afdefaeae37c512949c85c2c7674 Reviewed-by: Mark Brand <mabrand@mabrand.nl> (cherry picked from commit qtbase/8ccab9b029ed2a2444d89a9cfc6c4a1866b8e82d) Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* Fix QTBUG-18934 by checking return value of qt_safe_pipeSimeon Bird2013-02-281-9/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | When QProcess->start() is called, Qt creates a pipe to the process to get its exit value and output. It does this with qt_create_pipe, which calls qt_safe_pipe. qt_safe_pipe, on failure, returns 1. qt_create_pipe then sets errno and returns void. The calling function, QProcessPrivate::startProcess, does not check errno, and thus continues to fork the process, assuming the pipe has been created successfully. The child process then has no way to pass its exit value to the calling process, since the communication pipes it would normally use do not exist, and thus when it exits it becomes a zombie. As a bonus, if waitForFinished is called on a broken process, a crash results because it is trying to wait on a pipe which does not exist. The fix makes qt_create_pipe return an integer, and QProcess::startProcess check the return value, set processError and not create the child process. Task-Number: QTBUG-18934 Cherry-picked from qtbase f575dc214630b3e3ebd66477a623c78405724468 Change-Id: I2e1effdd0617be5b8c5492bcbcf5f2b1584b2241 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* SSL docs: Be more explicit about the threats of ignoring SSL errorsPeter Hartmann2013-02-272-5/+14
| | | | | | | | | ... because almost everybody gets it wrong almost every time. (cherry picked from commit eaa18f306341818165c2ee4fc22750da04d5e45e) Change-Id: I3ca1dfe9723d4d29339c2c0a1ebe421f5929c760 Reviewed-by: Richard J. Moore <rich@kde.org>
* Fix compilation of Qt Concurrent with gcc 4.3Thiago Macieira2013-02-271-1/+1
| | | | | | | | | | | | GCC 4.3 had support for decltype but not the new function syntax (which we call "auto function" for short). That meant the code did not compile. qtconcurrentrun.h:105: error: expected initializer before ‘->’ token Task-number: QTBUG-28984 Change-Id: I792276ec59c4f6e73f6137c517636e70c71ed849 (cherry-picked from Qt 5 commit 0c4f6c6ea9415bcc5fde3e34bf909f43a9c6483c) Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Fix DB2 driver X64 Linux BuildKarim Pinter2013-02-241-1/+1
| | | | | | | | | | On X64 Linux DB2 driver build give an error on BIGINT conversion to QVariant, casting it to qint64 solved the problem. Task-number: QTBUG-20172 Change-Id: Id11b8a4b1f4ed3d5ed9854dfb53526d401b7d97d (cherry picked from qtbase/c8e34ed678145f2e5709d39007e27e186d1bc1f9) Reviewed-by: Mark Brand <mabrand@mabrand.nl>