Age | Commit message (Collapse) | Author |
|
Replaced SWIFTEN_OVERRIDE with C++11 standard override
keyword.
Test-Information:
Tested on macOS 10.12.5 with clang trunk.
Change-Id: If89c6cc2a648662522a320834c314496c943a55a
|
|
Also removes -Winconsistent-missing-destructor-override from
the list of ignored clang warnings.
Test-Information:
Tested on macOS 10.12.5 with clang trunk.
Change-Id: Iad951879e01eb951a2a393399f55e4e37437c6a2
|
|
Test-Information:
Unit tests pass OK on Windows 10 and CentOS 7.3.
Change-Id: I33c9eb6b3e6409727350a44e6d5c88c5e8907275
|
|
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Fixes FileWriteBytestreamTest by closing WriteStream before file
deletion which passes.
Tests performed under Windows 10 1703
Change-Id: I0be891af652138af23f8db9e5526d927d39c9856
|
|
Found by cppclean.
Test-Information:
Still builds on macOS 10.12.5 with clang trunk.
Change-Id: Ie8a154e12b196587c956c8b333abf529a36f6bb3
|
|
Coverity raised this issue.
Test-Information:
All unit and integration tests, including the file-transfer
tests, passed on macOS 10.12.4.
Change-Id: I418358366478ad76e4eff4fb0a3559373931e111
|
|
* swift-3.x:
- Fix building Swift on 32-bit Linux distributions
- Remove optional_fwd.hpp use; workaround for Boost Bug #12179
- Split COPYING.thirdparty in contributions/dependencies
- Fixes for building packages on Debian
Conflicts:
BuildTools/SCons/SConstruct
Sluift/Console.h
Sluift/ITunesInterface.h
Sluift/Terminal.h
Swift/Packaging/Debian/debian/control.in
Swift/QtUI/SConscript
Swiften/Elements/Stanza.h
Swiften/FileTransfer/FileTransferTransporter.h
Swiften/FileTransfer/IBBReceiveSession.h
Swiften/JID/JID.h
Swiften/Network/BoostConnectionServer.h
Swiften/Network/ConnectionServer.h
Swiften/Parser/AttributeMap.h
Test-Information:
Builds on macOS 10.12.1 with clang trunk.
Change-Id: I9f41ab199f227bc106721627ea994313c68e5cfe
|
|
Test-Information:
Build on macOS 10.12.1 and all tests pass.
Change-Id: Iedaa3fa7e7672c77909fd0568bf30e9393cb87e0
|
|
Previously HostAddress had a constructor which allowed
initialisation via a std::string. This initialisation can
fail and this is heavily used for checking whether a string
is a valid IP address.
This constructor is removed in this commit and replaced by
a static method HostAddress::fromString, taking a string and
returning an optional HostAddress. This clearly communicates
that the conversion can fail.
Test-Information:
./scons test=all passes on macOS 10.12.1.
Change-Id: Idaafee6f84010ce541c55f267ac77ad6ac8f02b4
|
|
The FeatureOracle provides tri-state feature lookup
functionality for bare JIDs. It returns Yes if a feature is
supported by all resources of the bare JID, Maybe if some
support it, and No if none of the resources support it.
If passed a full JID, it returns the specific features supported
by that end-point.
Sending a file to a bare JID, will send a file to the resource
of the bare JID with the highest availability by presence, show
status and priority and which supports the features required
for a Jingle file-transfer.
Test-Information:
Added unit test verifying new behavior.
All tests pass on OS X 10.11.6. Added new unit tests for
FeatureOracle.
Manually verified that the roster and chat window both use
the same mechanism to detect support for file-transfers.
Manually verified that file-transfers via the contact list
goes to already bound full JIDs if there is an existing
ChatController.
Change-Id: I0175ac42ecb73f1d54f9c96ffbba773eb5e24296
|
|
Test-Information:
Builds on macOS 10.12 and unit tests pass.
Change-Id: Ia979e7dbd6f6c84085b1b951d81b925dffbed262
|
|
Initialised previously uninitialised class members. Changed
some raw pointers to std::unique_ptr for clearer and
automatically initialised code.
Test-Information:
Builds on macOS 10.12 and unit tests pass in ASAN-enabled
build.
Change-Id: I7900fe6131119c228ca92c79c0ee8125137f2e48
|
|
Test-Information:
Tested with a buggy XMPP client that calculates S5B DSTADDR
in a non-standard way. Previously this lead to Swift crashing
on an assert. Now Swift just indicates file-transfer failure
to the other party.
Change-Id: I4ed47f9647a1851f2a5101657bcd569c106d638f
|
|
Test-Information:
Test that it still builds and unit test pass on OS X 10.11.4.
Change-Id: I2eb4a0b707991aee553db36a8cd1ae28b813acab
|
|
Boost.Signals was deprecated and is not improved further.
This patch removes Boost.Signals from 3rdParty and adds
Boost.Signals2 and its dependencies.
Also removed the Qt signals compatibility file
Swiften/Base/boost_bsignals.h.
Test-Information:
Build and ran unit tests on OS X 10.11.4. Confirmed successful
login using Swift client.
Change-Id: Ie6e3b2d15aac2462cda95401582f5287a479fb54
|
|
This change was done by applying the following 'gsed'
replacement calls to all source files:
's/\#include <boost\/shared_ptr\.hpp>/\#include <memory>/g'
's/\#include <boost\/enable_shared_from_this\.hpp>/\#include <memory>/g'
's/\#include <boost\/smart_ptr\/make_shared\.hpp>/\#include <memory>/g'
's/\#include <boost\/make_shared\.hpp>/\#include <memory>/g'
's/\#include <boost\/weak_ptr\.hpp>/\#include <memory>/g'
's/boost::make_shared/std::make_shared/g'
's/boost::dynamic_pointer_cast/std::dynamic_pointer_cast/g'
's/boost::shared_ptr/std::shared_ptr/g'
's/boost::weak_ptr/std::weak_ptr/g'
's/boost::enable_shared_from_this/std::enable_shared_from_this/g'
The remaining issues have been fixed manually.
Test-Information:
Code builds on OS X 10.11.4 and unit tests pass.
Change-Id: Ia7ae34eab869fb9ad6387a1348426b71ae4acd5f
|
|
Run 'clang-tidy -fix -checks=modernize-use-nullptr' on all
source code files on OS X. This does not modernize platform
specific code on Linux and Windows
Test-Information:
Code builds and unit tests pass on OS X 10.11.4.
Change-Id: Ic43ffeb1b76c1a933a55af03db3c54977f5f60dd
|
|
Removed trailing spaces and whitespace on empty lines
in the process.
Changed CheckTabs.py tool to disallow hard tabs in source
files.
Test-Information:
Manually checked 30 random files that the conversion worked
as expected.
Change-Id: I874f99d617bd3d2bb55f02d58f22f58f9b094480
|
|
Changed "" style includes to <> style.
Test-Information:
Build with Clang 3.9.0 and ran all tests on OS X 10.11.4.
Change-Id: Ic05e53f2e5dba39cc1307b116fc5f17b62ab9eb8
|
|
Previously Jingle File Transfer in Swiften only used IBB
transport as fallback mechanism. With this patch Swiften will
use IBB transport candidates directly in the first
session-initate/session-accept message if the other party
only supports IBB.
Fixed a ASAN reported heap-use-after-free in
SOCKS5BytestreamServerManager.cpp while testing.
Test-Information:
./scons test=system passed without error.
Testing all sender/receiver file-transfer option configurations
with FileTransferTest resulting in expected behavior.
Successfully transferring a file between two Swift instances.
Change-Id: Ia0ffeaa1fd54fc0da23db75344c9e94f9d03a774
|
|
WriteBytestream::write(…) now returns a boolean indicating
its success state (false in case of an error). Adjusted
FileWriteBytestream accordingly.
The QtWebKitChatView will test if the file path selected by
the user is writable before accepting it and starting the
transfer. If it is not writable a red warning message will be
added to the file-transfer element in the chat view.
Test-Information:
Added an integration test that tests the new behavior for
the FileWriteBytestream class.
Tested two file transfers on OS X 10.11.3, one to a write
protected location and another to /tmp. The first is not accepted
by the UI, and without the UI sanity check it results in a
file-transfer error. The second succeeds as expected.
Change-Id: I5aa0c617423073feb371365a23a294c149c88036
|
|
This commit adds explicit code to stop timers which are
connected to objects that are about to be deleted from
memory.
Test-Information:
./scons test=system passes on OS X 10.11.3.
Change-Id: I139314f3a223e3dc63b78b96be17d3ae53cd3de3
|
|
Adds missing virtual keyword to destructors of classes which
have a non-empty destructor and are inheriting from other
classes and implement virtual functions.
Test-Information:
Compiles and unit tests pass on Windows 8 with VS 2013.
Change-Id: I172b5de8eda63eb8057113fbc979444abde3e0a7
|
|
This should enable IPv4/IPv6 dual-stack support for Swift(-en)
Jingle file-transfer support.
Add Connection::getRemoteAddress() method.
Test-Information:
Tested IPv6 file-transfer and IPv4 file-transfer between two
Swift instances.
Added integration test verifying IPv4 only, IPv6 only and
IPv4/IPv6 dual-stack support on the running platform.
Additionally added test to verify remote addresses on dual-stack
server.
Change-Id: Ie384a71833eacca554f69e6f12a1c8330d0d747f
|
|
Test-Information:
Tested by transferring a file between two Swift instances.
Tested in WebKit chat views and in plain chat views.
Change-Id: Ie46cbd7bac8a36478f64b4557cf55926e6d4af37
|
|
Test-Information:
Ran a file-transfer between two Swift instances and verified
no fe80:... addresses are included in the candidates.
Change-Id: I51dedb6aff95686764f74bf61ab2963e51ecbd1c
|
|
Canceling an IBB transfer in-flight caused an use-after-free
reported by ASAN. With this fix we keep a reference of the
current request around to be able to disconnect from its
signals on cancel.
Test-Information:
Transferred a file with Swift using the IBB method and canceled
the transfer. The previously error reported by ASAN is gone.
Change-Id: I240d3dbb59cddb6b91d49f268595a89ac8805f72
|
|
Test-Information:
Tested against a Swift instance which does not advertise the
DiscoInfo::JingleTransportsS5BFeature feature and verified
via debug console that only the IBB feature is listed in the
candidates.
Change-Id: I708c437f5c30c16c3478fd3448d7cb9592e68677
|
|
Test-Information:
Still builds and tests pass on OS X 10.10.5.
Change-Id: Ic616e7b9de443ce34b46de63ac1bb0cca34b08ee
|
|
With this commit
SOCKS5BytestreamProxiesManager::onDiscoveredProxiesChanged
will be emitted even if no proxies are found.
Move signal emission out of if/else scopes as it was present
in both cases.
Test-Information:
Tested file-transfer with the sender located at a server
without a S5B proxy.
Change-Id: Ic79928e539a6f39f23bfda370d701bf6d9ca9cbf
|
|
Test-Information:
Build and tests pass successfully on OS X 10.10.5.
Change-Id: I614586660796f9ef043156d09d998d39934a6eca
|
|
In addition, this adds the file-transfer classes to the
Doxygen documentation.
Test-Information:
Unit and integration tests still pass.
Change-Id: Ib6c16078c90ed56fae835cb2abfea8a564c3afa3
|
|
Test-Informations:
Code compiles without warnings and tests still pass.
Change-Id: If74c615706b8125c3c5186f0d940c103749ddb80
|
|
Test-Information:
Both Valgrind and clang's leak sanitizer report a lot leaks
on the FileTransferTest. With this commit it the stack traces
related to the fixed leaks are gone.
Change-Id: Idae9a81bcd8d97576d3f1469bf64490e0bfa7d55
|
|
This existing code was commented out. There are not tests for
it and no counterpart for incoming transfers.
We support Jingle-based file-transfers as the main file-transfer
method, as do lots of other clients.
Test-Informations:
Tested the complete project still builds.
Change-Id: Icf278165733fe481b4e2bc777a73bc420cf76398
|
|
The code used to call the onProxiesFound signal only if a
proxy was found. In case of missing S5B proxy at the users
server, the file-transfer preparation would hang.
Now the code wants until the discovery phase is done and then
calls the onProxiesFound signal with the list of discovered
proxies. In case of missing S5B proxy server the signal is
called with an empty list so the file-transfer flow can
continue.
Test-Information:
Ran FileTransferTest integration test and manually tested a
file-transfer on a server without S5B proxy.
Change-Id: I31d3cc08fe6453b5cdfe6be286f884a920470d28
|
|
FileTransferManagerImpl should have a virtual dtor, as the
parent class also has a virtual dtor.
Test-Information:
Unit tests still run.
Change-Id: I72a0757a930254caadfd1463b3f90af6c4829bd0
|
|
Added Swiften/Base/Concat.h to the exception list for <algorithm>
include, as Concat.h uses std::copy, defined in <algorithm>.
Added Swiften/FileTransfer/S5BTransportSession.h to the exception
list for <boost/bind.hpp> include, as S5BTransportSession.h
declares a template class using boost::bind.
Test-Information:
Tested that each of Swiften's public header files compiles on its
own.
Change-Id: Iac794b6e0f5959cd8261888a67761813b710fe85
|
|
Now Client allocates a FileTransferManager in its ctor and frees
it in its dtor, like all the other resources of the Client class.
This fixes an ASAN crash in the use case where you do a file
transfer, go offline and online again and try to start another
file transfer.
Test-Information:
Tested that the mentioned use case does not crash anymore,
that file transfers still work, and that FileTransferTest still
passes.
Change-Id: Iddbcd8522af7df528bdc2b030fe616ad3f0c4701
|
|
A recent commit introduced resolving of S5B proxy domain names
to their IPv4 and IPv6 addresses. With that a proxy identified
by a JID can have more than one host and we try them in parallel
until the first succeeds.
The old code just handled one host per proxy JID and a failed
IPv6 attempt would override the succeeded connection. The code
uses shared pointers and the succeeded connecting is deallocated
and disconnected when it is replaced with the failing IPv6
connection.
The result is the proxy server complaining that we are not
connected as we try to activate the proxy stream.
This commit changes the the proxy management to handle multiple
connections per proxy JID. Failing connections are removed from
the proxy sessions data structure. With the first succeeding
connections, others are stopped and also removed.
Test-Information:
Tested on Linux (Elementary OS 0.2) with
"Swiften/QA/FileTransferTest/FileTransferTest 4 4", which forces
the use of SOCKS5 bytestream proxy.
Change-Id: If3071c3d058e1040556bb72702bf83f4f5f25334
|
|
Test-Information:
This LSAN reported leak is gone with this fix.
Change-Id: Ib25fdfb7f4a82f62cd3f82ddb99f45618ea72ea9
|
|
Reported by LSAN.
Test-Information:
Detected by running FileTransferTest with LSAN on Linux.
The leak reports for the allocations in FileReadBytestream and
FileWriteBytestream are gone with this fix.
Change-Id: I32711990eca0c9a2a2982837cfac38cb11a28caa
|
|
Test-Information:
Detected with valgrind-3.10.1 on OS X 10.9.5 and verified they are
gone with this fix.
Change-Id: I8cab09efd2227a8d43fa77bd2c315bd9b67435fb
|
|
This is an attempt to fix crash reports with a segmentation fault on
call of onLocalTransportCandidatesGenerated().
Test-Information:
Tested that file-transfer still works.
Change-Id: I415be0d8bc5fa15dcd68d0794ee2478a0d836f27
|
|
Test-Information:
Added unit test that checks for the expected behavior.
Change-Id: I4079bdc1182af466eedd2496b9837e024f14acb2
|
|
If the S5B proxy lookup result has no direct IP address listed the
name is resolved using DNS. This change will create a proxy result
per resolved result address and not only the first result address.
Test-Information:
Verified the candidate list contains both entires for a proxy name
that resolves to an A and an AAAA record.
Change-Id: Iec21ff90af981030ff49fb53803d88a59694767c
|
|
ASAN reported heap-use-after-free because if the timer is running
and an instance is freed, the signal of the timer is still emitted and
connected slots are called.
Test-Information:
Tested that the ASAN report wents away with this fix.
Change-Id: Id785737c4c015e5c638e9d9f6419d740d6cf83b9
|
|
Test-Information:
Still builds
Change-Id: I93cd349364093eae320104b5b551c25da47b1d74
|
|
Due to missing signal connection and a copy'n'paste bug, Swift did not
wait for port forwarding/public IP detection before emitting the list
of local candidates. This is fixed now.
The signal is automatically disconnected when the file transfer
is finished and s5bServerPortForwardingUser_ is freed.
Test-Information:
Send a file between two Swift instances and verified log output.
Change-Id: I6530a7ac1cbf6941061bd99aa3f3b0624ebc984c
|
|
Test-Information:
Tested on Elementary OS with a LLVM/Clang 3.7.0 build. With this patch
the reports for the fixed locations are gone.
Change-Id: I0260fc85ad662335a69ace331f51ebe2f864ef97
|