Commit 6faede08 authored by Eike Ziller's avatar Eike Ziller
Browse files

Merge remote-tracking branch 'origin/2.6'

Conflicts:
	share/qtcreator/qml/qmlpuppet/commands/changenodesourcecommand.h
	share/qtcreator/qml/qmlpuppet/commands/tokencommand.h
	share/qtcreator/qml/qmlpuppet/container/reparentcontainer.h
	share/qtcreator/qml/qmlpuppet/qml2puppet/instances/componentnodeinstance.h
	share/qtcreator/qml/qmlpuppet/qmlpuppet/instances/nodeinstanceclientproxy.cpp
	src/plugins/git/gitsettings.cpp
	tests/manual/ssh/remoteprocess/remoteprocesstest.h

Change-Id: I00c294e6d911d272615e65fed58562399af97a4e
parents a299252a 14a2ff59
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
QWidget {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
GroupBox {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
GroupBox {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
QVBoxLayout {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
GroupBox {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
PropertyFrame {
......
......@@ -28,7 +28,7 @@
**
**************************************************************************/
import Qt 4.7
import QtQuick 1.0
import Bauhaus 1.0
import "../Qt/"
......
......@@ -4,6 +4,13 @@ Product {
type: ["installed_content"]
name: "SharedContent"
Group {
condition: qbs.targetOS == "macx"
qbs.installDir: "share/qtcreator/scripts"
fileTags: ["install"]
files: "qtcreator/scripts/openTerminal.command"
}
Group {
qbs.installDir: "share/qtcreator/designer"
fileTags: ["install"]
......@@ -124,7 +131,6 @@ Product {
fileTags: ["install"]
prefix: "qtcreator/qml/qmldump/"
files: [
"Info.plist.in",
"LGPL_EXCEPTION.TXT",
"LICENSE.LGPL",
"main.cpp",
......@@ -219,13 +225,13 @@ Product {
fileTags: ["install"]
prefix: "qtcreator/qml/qmlobserver/"
files: [
"Info.plist.in",
"LGPL_EXCEPTION.TXT",
"LICENSE.LGPL",
"deviceorientation.cpp",
"deviceorientation.h",
"deviceorientation_harmattan.cpp",
"deviceorientation_maemo5.cpp",
"deviceorientation_symbian.cpp",
"loggerwidget.cpp",
"loggerwidget.h",
"main.cpp",
......@@ -454,7 +460,6 @@ Product {
fileTags: ["install"]
prefix: "qtcreator/qml/qmlpuppet/qml2puppet/"
files: [
"Info.plist.in",
"main.cpp",
"qml2puppet.pro",
]
......@@ -486,7 +491,6 @@ Product {
fileTags: ["install"]
prefix: "qtcreator/qml/qmlpuppet/qmlpuppet/"
files: [
"Info.plist.in",
"main.cpp",
"qmlpuppet.pri",
"qmlpuppet.pro",
......@@ -756,15 +760,6 @@ Product {
]
}
Group {
qbs.installDir: "share/qtcreator/scripts"
fileTags: ["install"]
prefix: "qtcreator/scripts/"
files: [
"openTerminal.command",
]
}
Group {
qbs.installDir: "share/qtcreator/snippets"
fileTags: ["install"]
......@@ -887,6 +882,36 @@ Product {
]
}
Group {
qbs.installDir: "share/qtcreator/templates/qtquick2app"
fileTags: ["install"]
prefix: "qtcreator/templates/qtquick2app/"
files: [
"app.pro",
"main.cpp",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/qtquick2app/qml/app/qtquick20"
fileTags: ["install"]
prefix: "qtcreator/templates/qtquick2app/qml/app/qtquick20/"
files: [
"main.qml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/qtquick2app/qtquick2applicationviewer"
fileTags: ["install"]
prefix: "qtcreator/templates/qtquick2app/qtquick2applicationviewer/"
files: [
"qtquick2applicationviewer.cpp",
"qtquick2applicationviewer.h",
"qtquick2applicationviewer.pri",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/qtquickapp"
fileTags: ["install"]
......@@ -949,6 +974,102 @@ Product {
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-bardescriptor"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-bardescriptor/"
files: [
"bar-descriptor.xml",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-guiapp"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-guiapp/"
files: [
"bar-descriptor.xml",
"icon.png",
"main.cpp",
"mainwidget.cpp",
"mainwidget.h",
"mainwidget.ui",
"project.pro",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-qt5-bardescriptor"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-qt5-bardescriptor/"
files: [
"bar-descriptor.xml",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-qt5-guiapp"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-qt5-guiapp/"
files: [
"bar-descriptor.xml",
"icon.png",
"main.cpp",
"mainwidget.cpp",
"mainwidget.h",
"mainwidget.ui",
"project.pro",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-qt5-quick2app"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-qt5-quick2app/"
files: [
"bar-descriptor.xml",
"icon.png",
"main.cpp",
"project.pro",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-qt5-quick2app/qml"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-qt5-quick2app/qml/"
files: [
"main.qml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-quickapp"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-quickapp/"
files: [
"bar-descriptor.xml",
"icon.png",
"main.cpp",
"project.pro",
"wizard.xml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/bb-quickapp/qml"
fileTags: ["install"]
prefix: "qtcreator/templates/wizards/bb-quickapp/qml/"
files: [
"main.qml",
]
}
Group {
qbs.installDir: "share/qtcreator/templates/wizards/helloworld"
fileTags: ["install"]
......@@ -1062,21 +1183,6 @@ Product {
]
}
Group {
qbs.installDir: "share/qtcreator/translations"
fileTags: ["install"]
prefix: "qtcreator/translations/"
files: [
"README",
"check-ts.pl",
"check-ts.xq",
"extract-customwizards.xq",
"extract-externaltools.xq",
"extract-mimetypes.xq",
"translations.pro",
]
}
Group {
qbs.installDir: "share/qtcreator/welcomescreen"
fileTags: ["install"]
......
......@@ -28,22 +28,24 @@ writeln("")
writeln("Product {")
writeln(" type: [\"installed_content\"]")
writeln(" name: \"SharedContent\"")
writeln("")
writeln(" Group {")
writeln(" condition: qbs.targetOS == \"macx\"")
writeln(" qbs.installDir: \"share/qtcreator/scripts\"")
writeln(" fileTags: [\"install\"]")
writeln(" files: \"qtcreator/scripts/openTerminal.command\"")
writeln(" }")
filenamedict = {}
blacklist = [
scriptFileName,
"static.pro", "share.pro", "share.qbs",
"qtcreator_cs.ts",
"qtcreator_de.ts",
"qtcreator_es.ts",
"qtcreator_fr.ts",
"qtcreator_hu.ts",
"qtcreator_it.ts",
"qtcreator_ja.ts",
"qtcreator_pl.ts",
"qtcreator_ru.ts",
"qtcreator_sl.ts",
"qtcreator_uk.ts",
"qtcreator_zh_CN.ts"]
"Info.plist.in"
]
blacklistdirs = [
"qtcreator/translations",
"qtcreator/scripts"
]
for root, dirs, files in os.walk("."):
try:
dirs.remove('.moc')
......@@ -53,6 +55,10 @@ for root, dirs, files in os.walk("."):
except: pass
root = root.replace('\\', '/')
if root.startswith("./"):
root = path.normpath(root[2:])
if root in blacklistdirs:
continue
for file in files:
if not (file in blacklist):
if not root in filenamedict:
......@@ -61,9 +67,7 @@ for root, dirs, files in os.walk("."):
filenamedict[root].append(file)
for directory in sorted(filenamedict.iterkeys()):
prefix = directory.replace('\\', '/')
if prefix.startswith("./"):
prefix = path.normpath(prefix[2:])
prefix = directory
if not prefix.endswith("/"):
prefix += "/"
normalizedDirectory = path.normpath(directory.replace('\\', '/'))
......
.. _license:
.. highlight:: none
License
========================================
Botan (http://botan.randombit.net/) is distributed under these terms::
Copyright (C) 1999-2011 Jack Lloyd
2001 Peter J Jones
2004-2007 Justin Karneges
2004 Vaclav Ovsik
2005 Matthew Gregan
2005-2006 Matt Johnston
2006 Luca Piccarreta
2007 Yves Jerschow
2007-2008 FlexSecure GmbH
2007-2008 Technische Universitat Darmstadt
2007-2008 Falko Strenzke
2007-2008 Martin Doering
2007 Manuel Hartl
2007 Christoph Ludwig
2007 Patrick Sona
2010 Olivier de Gaalon
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions, and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions, and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) "AS IS" AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE,
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) OR CONTRIBUTOR(S) BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
......@@ -8,6 +8,7 @@ QtcLibrary {
".",
".."
]
cpp.defines: base.concat("AGGREGATION_LIBRARY")
Depends { name: "cpp" }
Depends { name: "Qt.core" }
......
......@@ -46,6 +46,7 @@
#include <QMutex>
#include <QMutexLocker>
#include <QNetworkProxy>
#include <QRegExp>
#include <QTcpSocket>
/*!
......@@ -328,7 +329,7 @@ void SshConnectionPrivate::handleIncomingData()
qDebug("state = %d, remote data size = %d", m_state,
m_incomingData.count());
#endif
if (m_state == SocketConnected)
if (m_serverId.isEmpty())
handleServerId();
handlePackets();
} catch (SshServerException &e) {
......@@ -343,39 +344,78 @@ void SshConnectionPrivate::handleIncomingData()
}
}
// RFC 4253, 4.2.
void SshConnectionPrivate::handleServerId()
{
#ifdef CREATOR_SSH_DEBUG
qDebug("%s: incoming data size = %d, incoming data = '%s'",
Q_FUNC_INFO, m_incomingData.count(), m_incomingData.data());
#endif
const int idOffset = m_incomingData.indexOf("SSH-");
if (idOffset == -1)
const int newLinePos = m_incomingData.indexOf('\n');
if (newLinePos == -1)
return; // Not enough data yet.
// Lines not starting with "SSH-" are ignored.
if (!m_incomingData.startsWith("SSH-")) {
m_incomingData.remove(0, newLinePos + 1);
m_serverHasSentDataBeforeId = true;
return;
m_incomingData.remove(0, idOffset);
if (m_incomingData.size() < 7)
return;
const QByteArray &version = m_incomingData.mid(4, 3);
if (version != "2.0") {
}
if (newLinePos > 255 - 1) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_ERROR,
"Identification string too long.",
tr("Server identification string is %1 characters long, but the maximum "
"allowed length is 255.").arg(newLinePos + 1));
}
const bool hasCarriageReturn = m_incomingData.at(newLinePos - 1) == '\r';
m_serverId = m_incomingData.left(newLinePos);
if (hasCarriageReturn)
m_serverId.chop(1);
m_incomingData.remove(0, newLinePos + 1);
if (m_serverId.contains('\0')) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_ERROR,
"Identification string contains illegal NUL character.",
tr("Server identification string contains illegal NUL character."));
}
// "printable US-ASCII characters, with the exception of whitespace characters
// and the minus sign"
QString legalString = QLatin1String("[]!\"#$!&'()*+,./0-9:;<=>?@A-Z[\\\\^_`a-z{|}~]+");
const QRegExp versionIdpattern(QString::fromLatin1("SSH-(%1)-%1(?: .+)?").arg(legalString));
if (!versionIdpattern.exactMatch(QString::fromLatin1(m_serverId))) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_ERROR,
"Identification string is invalid.",
tr("Server Identification string '%1' is invalid.")
.arg(QString::fromLatin1(m_serverId)));
}
const QString serverProtoVersion = versionIdpattern.cap(1);
if (serverProtoVersion != QLatin1String("2.0") && serverProtoVersion != QLatin1String("1.99")) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_VERSION_NOT_SUPPORTED,
"Invalid protocol version.",
tr("Invalid protocol version: Expected '2.0', got '%1'.")
.arg(SshPacketParser::asUserString(version)));
tr("Server protocol version is '%1', but needs to be 2.0 or 1.99.")
.arg(serverProtoVersion));
}
const int endOffset = m_incomingData.indexOf("\r\n");
if (endOffset == -1)
return;
if (m_incomingData.at(7) != '-') {
// Disable this check to accept older OpenSSH servers that do this wrong.
if (serverProtoVersion == QLatin1String("2.0") && !hasCarriageReturn) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_ERROR,
"Identification string is invalid.",
tr("Server identification string is invalid (missing carriage return)."));
}
if (serverProtoVersion == QLatin1String("1.99") && m_serverHasSentDataBeforeId) {
throw SshServerException(SSH_DISCONNECT_PROTOCOL_ERROR,
"Invalid server id.", tr("Invalid server id '%1'.")
.arg(SshPacketParser::asUserString(m_incomingData)));
"No extra data preceding identification string allowed for 1.99.",
tr("Server reports protocol version 1.99, but sends data "
"before the identification string, which is not allowed."));
}
m_keyExchange.reset(new SshKeyExchange(m_sendFacility));
m_serverId = m_incomingData.left(endOffset);
m_keyExchange->sendKexInitPacket(m_serverId);
m_keyExchangeState = KexInitSent;
m_incomingData.remove(0, endOffset + 2);
}
void SshConnectionPrivate::handlePackets()
......@@ -653,6 +693,8 @@ void SshConnectionPrivate::connectToHost()
m_error = SshNoError;
m_ignoreNextPacket = false;
m_errorString.clear();
m_serverId.clear();
m_serverHasSentDataBeforeId = false;
try {
if (m_connParams.authenticationType == SshConnectionParameters::AuthenticationByKey)
......
......@@ -168,6 +168,7 @@ private:
SshConnection *m_conn;
quint64 m_lastInvalidMsgSeqNr;
QByteArray m_serverId;
bool m_serverHasSentDataBeforeId;
};
} // namespace Internal
......
......@@ -45,8 +45,8 @@
#if defined(Q_OS_WIN) && defined(Q_CC_MINGW)
// Missing declarations for MinGW. This requires MinGW with gcc 4.6.
#if __GNUC__ == 4 && __GNUC_MINOR__ < 7 && (!defined(__MINGW64_VERSION_MAJOR) || __MINGW64_VERSION_MAJOR < 2)
// Missing declarations for MinGW 32.
#if __GNUC__ == 4 && (!defined(__MINGW64_VERSION_MAJOR) || __MINGW64_VERSION_MAJOR < 2)
typedef enum { } MIB_TCP_STATE;
#endif
......
......@@ -8,6 +8,8 @@ QtcLibrary {
Depends { name: "Qt.network" }
cpp.includePaths: "."
cpp.defines: base.concat("ZEROCONF_LIBRARY")
Properties {
condition: qbs.targetOS == "windows"
cpp.dynamicLibraries: "ws2_32"
......
......@@ -44,6 +44,8 @@
#include <projectexplorer/kitinformation.h>
#include <projectexplorer/projectexplorer.h>
#include <projectexplorer/projectexplorerconstants.h>
#include <qtsupport/qtkitinformation.h>
#include <qtsupport/qtparser.h>
#include <utils/qtcprocess.h>
#include <QVariantMap>
......@@ -193,6 +195,9 @@ bool MakeStep::init()
pp->setArguments(arguments);
setOutputParser(new GnuMakeParser());
QtSupport::BaseQtVersion *version = QtSupport::QtKitInformation::qtVersion(target()->kit());
if (version)
appendOutputParser(new QtSupport::QtParser);
if (tc)
appendOutputParser(tc->outputParser());
outputParser()->setWorkingDirectory(pp->effectiveWorkingDirectory());
......
......@@ -71,8 +71,6 @@
#include <QDir>
#include <QDialog>
#include <QFileDialog>
#include <QTemporaryFile>
using namespace Bazaar::Internal;
using namespace Bazaar;
......@@ -123,10 +121,10 @@ BazaarPlugin::BazaarPlugin()
m_optionsPage(0),
m_client(0),
m_commandLocator(0),
m_changeLog(0),
m_addAction(0),
m_deleteAction(0),
m_menuAction(0)
m_menuAction(0),
m_submitActionTriggered(false)
{
m_instance = this;
}
......@@ -138,8 +136,6 @@ BazaarPlugin::~BazaarPlugin()
m_client = 0;
}
deleteCommitLog();
m_instance = 0;
}
......@@ -552,20 +548,16 @@ void BazaarPlugin::showCommitWidget(const QList<VcsBase::VcsBaseClient::StatusIt
return;
}
deleteCommitLog();
// Open commit log
QString changeLogPattern = QDir::tempPath();
if (!changeLogPattern.endsWith(QLatin1Char('/')))
changeLogPattern += QLatin1Char('/');
changeLogPattern += QLatin1String("qtcreator-bzr-XXXXXX.msg");
m_changeLog = new QTemporaryFile(changeLogPattern, this);