Commit Graph
65 Commits
Author SHA1 Message Date
Kenneth Skovhede 40dd3c6816 Updated all license mentions to MIT 2024-02-28 15:45:30 +01:00
David Gileadi 88480f2ee2 Get actual exception when logging errors 2022-08-04 09:37:38 -07:00
Kenneth Hsu e964072690 Target .NET Framework 4.7.1.
This updates all projects to target .NET Framework 4.7.1.  The
TencentCOS and Tardigrade backends depend on .NET Standard 2.0.  When a
.NET Framework prior to 4.7.1 is targeted, the system cannot be sure
that all the dependencies exist, so it copies all dependent assemblies
to the output directory.  This causes many assemblies from the System
namespace to become bundled in the release.

https://stackoverflow.com/a/48875007

We had previously attempted to make individual projects target 4.7.1
(see pull request #4242), but this can cause compatibility issues when
4.6.2 projects depend on 4.7.1. projects.

This will require Mono 5.10.0 or greater (previously, we required 5.0.0
or greater).

https://www.mono-project.com/docs/about-mono/releases/5.10.0/#class-libraries

This fixes issue #4234.
2020-07-26 19:46:01 -07:00
Kenneth Hsu 83ac03843d Fix spelling errors in comments.
In doing so, we also normalized some line endings.
2019-12-14 09:52:55 -08:00
BlueBlock 815e30b63b update csproj toolverion and nuget packages 2019-07-31 13:20:03 -04:00
BlueBlock 08a1e9998a initial upgrade to framework 4.6.2
- no code changes except those noted below
- projects upgrade to 4.6.2
- wixinstaller project upgraded automatically by VisualStudio
- wixinstaller updated to require 4.6.2
- Library.Encryption changed to Standard2.0 so accommodate update to SharpAesCrypt
2019-07-26 09:18:16 -04:00
Kenneth Hsu 81b9e75a29 Preserve stack trace while unwrapping TargetInvocationExceptions.
If we simply throw the inner exception, the stack trace is lost.  If we
throw a new exception with the originating exception as the inner
exception, the user is not provided with any meaningful information.
2019-03-21 19:26:14 -07:00
verhoek 9f46543418 Generically we don't want to throw an exception for an empty passphrase:
for GPG this is fine, since GPG either invokes the system's keychain
or will cause an exception.
2018-11-20 20:13:24 +01:00
Kenneth Hsu 0c1ac9c489 Replace chained LINQ calls with call to overload with predicate.
This simplifies the code by reducing the number of enumerators created
while also making the code slightly more readable.
2018-10-06 16:20:18 -07:00
Kenneth Hsu f12858e6a5 Mark fields that shouldn't be reassigned as readonly.
This makes it explicit at compile-time that these fields should not be
reassigned outside the constructor.
2018-05-25 10:04:52 -07:00
Kenneth Hsu cb0a3ed2a1 Make constructors for abstract classes protected.
While this does not affect any behavior, it more accurately describes
the accessibility.  Since abstract classes can only be instantiated by
an instance of a derived type, the constructors should at most have
protected access.
2018-04-07 18:04:41 -07:00
Tyler Gill c9e8ee31ab When unwrapping TargetInvocationException, we should still put the inner exception in a new Exception.
Otherwise, the callstack in the exception is overwritten, hiding the original call stack where the exception actually occurred.
2018-03-23 15:10:05 -06:00
Kenneth Hsu c00c6fd19b Make fields containing lock objects readonly.
If one of these fields is accidentally reassigned, it's possible for
threads to be oblivious to an existing lock.  By making the fields
readonly, we will be notified at compile-time if we inadvertently
redefine one of these fields.
2018-03-17 19:59:23 -07:00
Kenneth Skovhede e124329f1e Merge branch 'feature/improved-logging' 2018-03-16 08:38:14 +01:00
Kenneth Skovhede 842fd96543 Implemented a new logging system that is more transparent and allows a more granular way of picking log messages.
Added ID's to each log message and each exception to allow later introduction of a Knowledgebase service that explains each error in more detail.
2018-03-15 09:12:34 +01:00
Kenneth SkovhedeandGitHub 96cd4dd725 Merge pull request #3087 from warwickmm/use_nameof_operator
Use nameof operator when constructing ArgumentNullException
2018-03-08 11:14:49 +01:00
Kenneth Hsu d7b393ed98 Add missing XML parameter documentation. 2018-03-07 19:14:57 -08:00
Kenneth Hsu 46f9fd02b5 Remove XML documentation for unmatched parameters. 2018-03-07 19:13:50 -08:00
Kenneth Hsu 1f8b542604 Use nameof operator when constructing ArgumentNullException.
This will make rename refactorings easier in the future.
2018-03-07 17:53:08 -08:00
vnau 62a7901aca Compression modules refactored to work with streams instead of filenames;
Added unit test to check compression reversibility
2017-12-25 04:12:19 +07:00
Kenneth Hsu ab489d9a28 Make parameter names in XML documentation match code. 2017-12-09 18:42:30 -08:00
Kenneth Hsu 8810e0130d Make string comparisons use ordinal (binary) sort rules.
These string comparisons should not be culture-aware.
2017-11-26 11:19:54 -08:00
Kenneth Hsu 3d51e9153b Avoid signing assemblies.
Using strong-named assemblies can cause difficulties with the GNU LGPL
license, which allows for one to recombine or relink their application
with modified versions of the code.  While one solution is to share the
private key so that people can sign the assemblies themselves, this
would break the trust that is expected from signed assemblies.  For now,
the easiest fix is to simply not sign the assemblies.  Note that by
doing so, we prevent the code from being referenced from other signed
assemblies.

This also fixes an issue introduced in revision ba94d36a80 ("Added
auto-update for WindowsService and Service."), where the WindowsService
project (signed) referenced the AutoUpdater project (not signed).

We also removed instances of <SignAssembly>false</SignAssembly> to be
consistent with newly created .csproj files that do not contain the
SignAssembly element.

This was motivated by the discussion in issue #2814.
2017-10-15 22:00:23 -07:00
Tyler Gill 83a1dcfb64 Replace all instances of InvariantCultureIgnoreCase with OrdinalIgnoreCase in string comparisons.
InvariantCulture is useful when comparing / sorting human language strings in a culturely correct way. It handles things like accented letters in a way that makes sense to humans (e.g., 'a' should be sorted next to 'á', rather than after 'z').
Ordinal looks just at the raw code points of the characters. As such, it is recommended for use in cases when comparing system strings (file paths, command line parameters, config settings, etc.). Since it doesn't need to use the culture specific sorting rules, this method can often be faster.

For more information, see https://stackoverflow.com/questions/492799/difference-between-invariantculture-and-ordinal-string-comparison (and other related questions)
2017-09-18 23:55:08 -06:00
Kenneth Skovhede 1424be05f9 Fixed a bunch of typos.
This fixes #2278.
2017-01-23 22:12:24 +01:00
Kenneth Skovhede 52eb8e8478 Disabled MSBuild for much faster builds on MacOS 2016-12-29 23:12:41 +01:00
Kenneth Skovhede 3005594b38 Merge branch 'master' into nuget_setup
# Conflicts:
#	Duplicati/GUI/Duplicati.GUI.TrayIcon/Duplicati.GUI.TrayIcon.csproj
#	Duplicati/Library/Backend/S3/Duplicati.Library.Backend.S3.csproj
#	Duplicati/Library/Backend/S3/S3Wrapper.cs
#	thirdparty/CoCoL/CoCoL.dll
#	thirdparty/SSH.NET/Renci.SshNet.dll
2016-06-27 15:25:52 +02:00
Kenneth Skovhede 785c4d325f Reverted changes to solution file so it again forces Windows linefeeds.
This also moved stuff around in some project files.
2016-04-13 00:36:22 +02:00
Kenneth Skovhede 59cc0005a3 Removed unused references and updated most libraries to come from NuGet sources instead of being provided in the thirdparty library 2016-01-29 10:47:39 +01:00
Kenneth Skovhede b68290b95a Follow up to the latest pull request, changed all references to HexaD to "Duplicati Team" 2015-05-17 11:06:07 +02:00
Fabian Trampusch 55a853463d update year to 2015 2015-05-16 21:15:39 +02:00
Kenneth Skovhede 0d7cf7203b Updated to .Net framework version 4.5 2015-01-26 11:22:52 +01:00
Kenneth Skovhede 3149064cde Merge branch 'no_more_resx' 2015-01-20 21:45:54 +01:00
Kenneth Skovhede 8d13e698eb Updated copyright notices 2015-01-20 21:44:52 +01:00
Kenneth Skovhede 16c791f0b5 Removed all resx files, now using Duplicati.Library.Localization exclusively 2015-01-20 21:07:24 +01:00
Kenneth Skovhede b5de1b56ce Updated copyright year on all assemblies.
Also removed the copyright microsoft statement that was erroneously applied to some assemblies.
This fixes issue #1083.
2014-08-12 13:31:30 +02:00
Kenneth Skovhede cd6ad555b5 Improved error messages when loading modules 2014-07-15 13:33:32 +02:00
Kenneth Skovhede 69bd080aa5 Updated the version number in all projects to 2.0.0.7 2014-06-13 15:08:51 +02:00
Kenneth Skovhede e70ba0a477 Updated product-number in the project files 2014-06-13 15:00:12 +02:00
Kenneth Skovhede cef41557db Missing imports 2014-03-12 10:21:42 +01:00
Kenneth Skovhede 81ebf21597 Added test-backend command and web modules 2014-03-12 01:41:25 +01:00
Kenneth Skovhede e5b3f0ea93 Rewrote all backends to use the new Uri parser.
Updated the regex to be a little more forgiving.
Does not handle paths with @, like "ftp://server/@folder"
2013-05-05 23:46:00 +02:00
Kenneth Skovhede 62c75d9af9 Removed all informs code (no more 1.3.x UI) 2013-05-05 17:07:24 +02:00
Kenneth Skovhede 0014b69ccf Removed unused x86 configurations and fixes som build refrences 2013-05-05 13:45:02 +02:00
Kenneth Skovhede 066e4e6106 Fixed some bugs with the new url-parsing system 2013-05-05 13:09:55 +02:00
Kenneth Skovhede 23e09566fb Missing commit 2013-05-04 14:27:30 +02:00
Kenneth Skovhede e80a591932 Added +s suffix for protocols, so that ftps and webdavs are supported uri schemes 2013-05-04 14:23:10 +02:00
Kenneth Skovhede e353a89fa8 Added code to parse url query strings for backends, and use that as options 2013-05-02 21:12:46 +02:00
kenneth@hexad.dk 7e5dd2d581 Update command line help to use a friendlier format.
git-svn-id: https://duplicati.googlecode.com/svn/trunk@1258 59da171f-624f-0410-aa54-27559c288bec
2012-05-08 18:32:31 +00:00
kenneth@hexad.dk a571f239fb Fixed some build issues after the merge.
Also fixed the build problems with MonoDevelop (non-signed assemblies)

git-svn-id: https://duplicati.googlecode.com/svn/branches/v2.0@1009 59da171f-624f-0410-aa54-27559c288bec
2011-11-18 23:47:27 +00:00