platform/upstream/dotnet/runtime.git
6 years agoUpdate Tizen CI RID (dotnet/corefx#30692)
Gleb Balykov [Wed, 27 Jun 2018 12:07:20 +0000 (15:07 +0300)]
Update Tizen CI RID (dotnet/corefx#30692)

* Update Tizen RID for CI

* Update Tizen url for rootfs generation

Commit migrated from https://github.com/dotnet/corefx/commit/cdb337284ccce4a524caca2bdec029a0903b78e5

6 years agoDisable DrawBezier/DrawLine_PointFs tests (dotnet/corefx#30684)
Santiago Fernandez Madero [Wed, 27 Jun 2018 01:51:31 +0000 (18:51 -0700)]
Disable DrawBezier/DrawLine_PointFs tests (dotnet/corefx#30684)

Commit migrated from https://github.com/dotnet/corefx/commit/a9aabd2b7cf913f9dd35492d2f3497b2fb269978

6 years agoMerge pull request dotnet/corefx#30342 from AfsanehR/AccessTokenAAD
Afsaneh Rafighi [Tue, 26 Jun 2018 22:58:41 +0000 (15:58 -0700)]
Merge pull request dotnet/corefx#30342 from AfsanehR/AccessTokenAAD

Azure Active Directory Authentication using Access Token

Commit migrated from https://github.com/dotnet/corefx/commit/a74bf4200926c47c11ba0383e2bddeaa59227266

6 years agoMerge branch 'master' into AccessTokenAAD
Afsaneh Rafighi [Tue, 26 Jun 2018 19:54:34 +0000 (12:54 -0700)]
Merge branch 'master' into AccessTokenAAD

Commit migrated from https://github.com/dotnet/corefx/commit/da34501f05ede07fb4703ad10ab9b563a3a34790

6 years agoadd option to handle Ping TTL for raw socket and system utility (dotnet/corefx#30324)
Tomas Weinfurt [Tue, 26 Jun 2018 18:00:00 +0000 (11:00 -0700)]
add option to handle Ping TTL for raw socket and system utility (dotnet/corefx#30324)

* add option to handle TTL for raw socket and system utility

* add missing blank line

* incorporate feedback and merge with upstream

* feedback from review

Commit migrated from https://github.com/dotnet/corefx/commit/3035218ef5499c8786e242963298181ce22c5745

6 years agoAdd regression test for dotnet/corertdotnet/corefx#6016 (dotnet/corefx#30664)
Michal Strehovský [Tue, 26 Jun 2018 13:57:47 +0000 (15:57 +0200)]
Add regression test for dotnet/corertdotnet/corefx#6016 (dotnet/corefx#30664)

Commit migrated from https://github.com/dotnet/corefx/commit/271c0832d9b01958e147487352a2ef1eeab15d5c

6 years agoSimplify built-in types across corefx tests (dotnet/corefx#30660)
Stephen Toub [Tue, 26 Jun 2018 05:42:04 +0000 (01:42 -0400)]
Simplify built-in types across corefx tests (dotnet/corefx#30660)

Commit migrated from https://github.com/dotnet/corefx/commit/7ae1a252d7e68c5513d2658de7a401c37e9b0504

6 years agoMerge pull request dotnet/corefx#30570 from dotnet-maestro-bot/master-UpdateDependencies
Stephen Toub [Tue, 26 Jun 2018 03:55:07 +0000 (23:55 -0400)]
Merge pull request dotnet/corefx#30570 from dotnet-maestro-bot/master-UpdateDependencies

Update BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview1-02921-01, preview1-26624-03, preview1-26624-03, preview1-26624-01, beta-26622-00, beta-26622-00, respectively (master)

Commit migrated from https://github.com/dotnet/corefx/commit/14d17b207ff405892e56cc0e25c8e20f1f7f672f

6 years agoSimplify built-in types across corefx (dotnet/corefx#30656)
Stephen Toub [Mon, 25 Jun 2018 23:54:41 +0000 (19:54 -0400)]
Simplify built-in types across corefx (dotnet/corefx#30656)

Commit migrated from https://github.com/dotnet/corefx/commit/e0ba7aa8026280ee3571179cc06431baf1dfaaac

6 years agoRemove netcorepp2.2 from package testing
Wes Haggard [Mon, 25 Jun 2018 19:46:27 +0000 (12:46 -0700)]
Remove netcorepp2.2 from package testing

Commit migrated from https://github.com/dotnet/corefx/commit/d77efb0302ed5ca8f029a4960c8b995f193cd16c

6 years agoFixes and workarounds for new CoreCLR
Jan Kotas [Sun, 24 Jun 2018 23:28:32 +0000 (16:28 -0700)]
Fixes and workarounds for new CoreCLR

Commit migrated from https://github.com/dotnet/corefx/commit/32646dfea2e43e4235c2973e10e007e14d62978e

6 years agoUpdate BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to...
dotnet-maestro-bot [Sun, 24 Jun 2018 13:40:44 +0000 (06:40 -0700)]
Update BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview1-02921-01, preview1-26624-03, preview1-26624-03, preview1-26624-01, beta-26622-00, beta-26622-00, respectively

Commit migrated from https://github.com/dotnet/corefx/commit/b3d06972830374351dabeeb3cd71bbbfebeac29d

6 years agoUse public implementation MarshalSupport (dotnet/corefx#30494)
Luqun Lou [Mon, 25 Jun 2018 12:20:55 +0000 (05:20 -0700)]
Use public implementation MarshalSupport (dotnet/corefx#30494)

* Use public implementation MarshalSupport

* Implement NotifyCollectionChangedEventArgsMarshaler ConvertToManaged and PropertyChangedEventArgsMarshaler ConvertToNative

* Refactor RoGetActivationFactory into Common

* Update according to comments and add an analyzerdata file

Commit migrated from https://github.com/dotnet/corefx/commit/098d8626dca87dd809fde77784c04eb9d00a2a3d

6 years agoaddressed review feedbacks
Afsaneh Rafighi [Mon, 25 Jun 2018 04:11:14 +0000 (21:11 -0700)]
addressed review feedbacks

Commit migrated from https://github.com/dotnet/corefx/commit/98a9ccb74a6204901d3becd6e453eddd61e5db5d

6 years agoHandle empty region scans on Unix.
Jeremy Kuhne [Sun, 24 Jun 2018 18:17:03 +0000 (11:17 -0700)]
Handle empty region scans on Unix.

Commit migrated from https://github.com/dotnet/corefx/commit/abe3710c12f61c5958477cbf2158c26c417828a9

6 years agoRemove GPRECT and GPRECTF
Jeremy Kuhne [Sun, 24 Jun 2018 04:05:49 +0000 (21:05 -0700)]
Remove GPRECT and GPRECTF

They match directly with Rectangle/RectangleF

Commit migrated from https://github.com/dotnet/corefx/commit/9123e8ff2ccda39fa0abc2a0aeb07874ff217ae6

6 years agoStyle cleanup in preparation of perf fixes.
Jeremy Kuhne [Sun, 24 Jun 2018 03:32:48 +0000 (20:32 -0700)]
Style cleanup in preparation of perf fixes.

Commit migrated from https://github.com/dotnet/corefx/commit/a0dd2fc0cf3f53233fee56c81e5eb9bd690e58ac

6 years agodocs: ActivityUserGuide.md typo (dotnet/corefx#30634)
Meir Blachman [Sun, 24 Jun 2018 18:59:27 +0000 (21:59 +0300)]
docs: ActivityUserGuide.md typo (dotnet/corefx#30634)

Commit migrated from https://github.com/dotnet/corefx/commit/8c906fbabc79c23c56edcb87b70dd22c7173d76a

6 years agoUpdate to latest released dotnet SDK (dotnet/corefx#30633)
Jan Kotas [Sun, 24 Jun 2018 18:58:54 +0000 (11:58 -0700)]
Update to latest released dotnet SDK (dotnet/corefx#30633)

Commit migrated from https://github.com/dotnet/corefx/commit/4a2154cb309e5d4ecdf2ec2ee0075561f4ca0cd2

6 years ago Update performance counter interop to use Span<T> (dotnet/corefx#30614)
Jan Kotas [Sun, 24 Jun 2018 14:18:49 +0000 (07:18 -0700)]
 Update performance counter interop to use Span<T> (dotnet/corefx#30614)

* Move NtProcessInfoHelper to ProcessManager.Win32.cs

NtProcessInfoHelper was split between ProcessManager.Win32.cs and ProcessManager.Windows.cs for no good reason

* Update performance counter interop to use Span<T>

This is both faster and more secure

* Delete FEATURE_TRACESWITCH

Commit migrated from https://github.com/dotnet/corefx/commit/d1cdb1b324ea6b52d2b4026bdcc7c2ee1e00b63c

6 years agoNetFX compatibility fixes for X500DistinguishedName.
Filip Navara [Sun, 24 Jun 2018 04:29:39 +0000 (06:29 +0200)]
NetFX compatibility fixes for X500DistinguishedName.

* Don't write a separator after the empty DN
* Make T61String behave like it does on Windows (UTF-8 with a Latin-1 fallback)
* Use the managed decoder on Linux, instead of a lot of P/Invokes back into OpenSSL.

Commit migrated from https://github.com/dotnet/corefx/commit/5e3aecf952ea5810b82293312fd840d4fdaa13d3

6 years agoKill allocations in GraphicsPath/Graphics
Jeremy Kuhne [Sat, 9 Jun 2018 23:16:27 +0000 (16:16 -0700)]
Kill allocations in GraphicsPath/Graphics

This removes a great deal of the unneeded allocations in GraphicsPath and Graphics. Points and rectangles match the native types exactly and don't need special marshalling outside of pinning arrays.

This removes all usages of GPPOINT/F.  Many GPRECT/F usages were removed, but still exist in other classes.

Commit migrated from https://github.com/dotnet/corefx/commit/7d95fd47402872de4deaca20f46586e0cb330e7c

6 years agoAdd using for SafeNativeMethods.Gdip
Jeremy Kuhne [Sat, 23 Jun 2018 19:00:08 +0000 (12:00 -0700)]
Add using for SafeNativeMethods.Gdip

Commit migrated from https://github.com/dotnet/corefx/commit/cf4ca262a66b4e2e87f90a5565ef474b992707b3

6 years agoClean style in Graphics/GraphicsPath
Jeremy Kuhne [Sat, 9 Jun 2018 23:00:07 +0000 (16:00 -0700)]
Clean style in Graphics/GraphicsPath

Make a consistency pass through Graphics & GraphicsPath.

Plan is to follow up with a change that removes the rest of the unnecessary allocations.

This change focuses on the Windows specific code. Some Unix code will be able to be unified with the Windows code once further changes happen. Rather than reformat the Unix code preemptively, leaving for final follow-up.

Commit migrated from https://github.com/dotnet/corefx/commit/e448b6c5d5c9648ab9c1e6c5490c6f9ac6d1bd4c

6 years agoDecimal.Remainder tests (dotnet/corefx#30291)
Pent Ploompuu [Sat, 23 Jun 2018 23:48:33 +0000 (02:48 +0300)]
Decimal.Remainder tests (dotnet/corefx#30291)

* Decimal.Remainder tests

* Remove quirk for NearNegativeZero/NearPositiveZero scaling issue

Commit migrated from https://github.com/dotnet/corefx/commit/3e107903bf6070bcae7b10986c0dabb4c7b03454

6 years agoMake ControlChars public (dotnet/corefx#30551)
EdwinEngelen [Sat, 23 Jun 2018 18:55:41 +0000 (20:55 +0200)]
Make ControlChars public (dotnet/corefx#30551)

* Make ControlChars public

Accessibility now matches .NET Framework.

* Correct typo in comment

Commit migrated from https://github.com/dotnet/corefx/commit/c555c7db2f53392eba90f1dfa1e46de92ebc1ae2

6 years agoChange string.Compare(..., Ordinal{IgnoreCase}) == 0 to use Equals (dotnet/corefx...
Stephen Toub [Sat, 23 Jun 2018 14:22:18 +0000 (10:22 -0400)]
Change string.Compare(..., Ordinal{IgnoreCase}) == 0 to use Equals (dotnet/corefx#30620)

Commit migrated from https://github.com/dotnet/corefx/commit/963536c7b4f35363b9837c2f279e522aa237c84e

6 years agoUse public implementation WindowsRuntime ExceptionSupport (dotnet/corefx#30440)
Luqun Lou [Sat, 23 Jun 2018 02:45:05 +0000 (19:45 -0700)]
Use public implementation WindowsRuntime ExceptionSupport (dotnet/corefx#30440)

Commit migrated from https://github.com/dotnet/corefx/commit/585a9306ec049548680417e70765820b69c2d70f

6 years agoPass RID to crossgen (dotnet/corefx#30562)
Adeel Mujahid [Sat, 23 Jun 2018 02:40:39 +0000 (05:40 +0300)]
Pass RID to crossgen (dotnet/corefx#30562)

Commit migrated from https://github.com/dotnet/corefx/commit/4aaf685b42201cbdb407c2cd3d3e0bcba72f3977

6 years agoFix race in TaskCancelWaitTestCases.TaskCancelWait1() (dotnet/corefx#30615)
Alexander Köplinger [Sat, 23 Jun 2018 01:56:53 +0000 (03:56 +0200)]
Fix race in TaskCancelWaitTestCases.TaskCancelWait1() (dotnet/corefx#30615)

When `CancelChildren` is enabled (currently only in the `TaskCancelWait1` test)
we're hitting a race in `TaskCancelWaitTest.CreateTask()`:

1. Let's assume Task A is processing `node`
2. Task A spawns a new Task B for processing `node_1`
3. Task B starts and signals the `_countdownEvent`
4. `RealRun()` on the main thread exits the wait on `_countdownEvent`
5. `RealRun()` calls `Verify()` which loops through all the nodes and calls `VerifyCancel()`
6. We get an assertion because `CancellationToken.IsCancellationRequested` is false
7. Task A continues and sets the CancellationToken, but it is already too late by this point

To fix this race we wait on the task in `RealRun()` before proceeding to
the verification step.

This uncovered another issue:
Since `_countdownEvent` is accessed by multiple threads we have another
race between checking `_countdownEvent.IsSet` and `_countdownEvent.Signal()`.
This caused a `System.InvalidOperationException: Invalid attempt made to decrement the event's count below zero.`
Fixed it by locking access to the `_countdownEvent`.

Fixes https://github.com/dotnet/corefx/issues/20457
Fixes https://github.com/mono/mono/issues/6920

Commit migrated from https://github.com/dotnet/corefx/commit/69cf791e365c2be6f919929c5ae521b2e070aa5d

6 years agoMove S.T.M. Span<char> tests to StringTests.cs(part 4) (dotnet/corefx#30301)
Marco Rossignoli [Sat, 23 Jun 2018 00:08:18 +0000 (02:08 +0200)]
Move S.T.M. Span<char> tests to StringTests.cs(part 4) (dotnet/corefx#30301)

* merge IsWhiteSpace.cs

* nit: add space after comma

* fix netfx compat issue

* merge SequenceCompareTo.char.cs SequenceEqual.char.cs StartsWith.char.cs StartsWith.StringComparison.cs

* fix SequenceEqual tests

* merge TrimAnyCharacter.cs

* merge TrimManyCharacters.cs TrimWhiteSpace.cs

* address PR feedback

* Address PR feedback

* address PR feedback

* move ToLower.cs

* move ToUpper.cs and fix some tests

* address PR feedback

* nit spaces

* rename empty to emptyString

* nit spaces

* add missed tests in merge

* fix test

* fix Ctor_SByte test

* remove var for .AsSpan()

Commit migrated from https://github.com/dotnet/corefx/commit/2566e24c97eb52ca2b0d22a8fe640e3a53230b51

6 years agoEnable testing against NetFX for S.S.C.X509Certificates.Tests
Jeremy Barton [Fri, 22 Jun 2018 22:07:27 +0000 (15:07 -0700)]
Enable testing against NetFX for S.S.C.X509Certificates.Tests

* Make S.S.C.X509Certificates.Tests compile against netstandard
* Fix or disable tests for netfx behavior
* Make the casing of the default X509Store Name value match netfx
* Suppress brainpool GetECDsaPublicKey tests on netfx

Commit migrated from https://github.com/dotnet/corefx/commit/6fe9969761bce606bdf76f8f580c3c3849fb9327

6 years agoSync SR class with the CoreRT copy
Michal Strehovský [Fri, 22 Jun 2018 11:50:51 +0000 (04:50 -0700)]
Sync SR class with the CoreRT copy

This ports over the change from
https://github.com/dotnet/corert/commit/dotnet/corefx@0ac83cb8d6f9ab10df616a608fcf6fdfa6eabe2b.

When UsingResourceKeys is true and we stripped the resources, the
existing code would have returned null.

Commit migrated from https://github.com/dotnet/corefx/commit/39e96cd8e3b97f8b1a5fce86211cf8fec7ea478a

6 years agoMove new SignedCms/EnvelopedCms API to netcoreapp/uap refs
Jeremy Barton [Fri, 22 Jun 2018 15:29:30 +0000 (08:29 -0700)]
Move new SignedCms/EnvelopedCms API to netcoreapp/uap refs

Commit migrated from https://github.com/dotnet/corefx/commit/d622e90b0ad884f6d895dec882ccbd60ebd96acb

6 years agoConsolidate Font code and fix Unix compat bugs (dotnet/corefx#29673)
Hugh Bellamy [Fri, 22 Jun 2018 02:30:32 +0000 (03:30 +0100)]
Consolidate Font code and fix Unix compat bugs (dotnet/corefx#29673)

* Consolidate Font code

* Enable tests that pass already

These already pass - i.e. not as a result of this PR

Commit migrated from https://github.com/dotnet/corefx/commit/80dc5bbbc8e10b4aaf6450d778fe46e303ce0e99

6 years agoPort over non-redundant Span tests from corefxlab dotnet/corefx#28281 (dotnet/corefx...
Ross Slaney [Fri, 22 Jun 2018 02:14:55 +0000 (19:14 -0700)]
Port over non-redundant Span tests from corefxlab dotnet/corefx#28281 (dotnet/corefx#30411)

* ported covariantslicenotsupported tests from corefxlab

* ported majority of non-redundant overflow tests from corefxlab

* Changed overlow.cs and covariantslicenotsupported.cs to conform to style guidelines

* changed covariantslicenotsupported tests to Assert.Throws pattern

* designated slicestartint32overflow test as outerloop

* Added more explicit declarations for local variables and removed a redundnat test

* Moved covariantslicenotsupported functions to AsSpan file, and removed unnecessary tests. Removed redundant function from overflow.cs

* adjusted overflow.cs tests to use Allocation helper and made them skip on 32-bit platforms. Removed UInt32 versions of slice overflow tests.

Commit migrated from https://github.com/dotnet/corefx/commit/b6b795129ca131e3c506fceb9dd4f60758a006bb

6 years agoAdd CoreLib to CI coverage (dotnet/corefx#30585)
Paulo Janotti [Fri, 22 Jun 2018 02:07:45 +0000 (19:07 -0700)]
Add CoreLib to CI coverage (dotnet/corefx#30585)

Commit migrated from https://github.com/dotnet/corefx/commit/64c9111cc3b1976d3c88cf376543b4b4158ef743

6 years agoAdd System.Data.Common.DataTableMapping unit tests. (dotnet/corefx#30550)
Leonardo Teixeira Menezes [Fri, 22 Jun 2018 02:06:11 +0000 (23:06 -0300)]
Add System.Data.Common.DataTableMapping unit tests. (dotnet/corefx#30550)

* Fix test spelling error.

* Add unit tests of System.Data.Common.DataTableMapping.

* Removes unnecessary action variable assignments in unit tests.

* Add license header on test file.

Commit migrated from https://github.com/dotnet/corefx/commit/cb6e15ac989250469a33d773c3895f4dd22c3592

6 years agoDispose SafeHandle on error path (dotnet/corefx#30583)
Jan Kotas [Fri, 22 Jun 2018 00:51:04 +0000 (17:51 -0700)]
Dispose SafeHandle on error path (dotnet/corefx#30583)

Commit migrated from https://github.com/dotnet/corefx/commit/aff570af58f834cab586034f6762017252b1f1d6

6 years agoReview feedbacks from Stephen Toub + Added a verification test
Afsaneh Rafighi [Thu, 21 Jun 2018 23:23:45 +0000 (16:23 -0700)]
Review feedbacks from Stephen Toub + Added a verification test

Commit migrated from https://github.com/dotnet/corefx/commit/0cf8f7d09502d69c78bdf811d5982d7a2143a88a

6 years agoAlign X509EnhancedKeyUsageExtension.EnhancedKeyUsages behaviour with NetFX
Filip Navara [Thu, 21 Jun 2018 18:04:35 +0000 (20:04 +0200)]
Align X509EnhancedKeyUsageExtension.EnhancedKeyUsages behaviour with NetFX

Commit migrated from https://github.com/dotnet/corefx/commit/7ab991767e4453058f07393de1bf6ab7d8b90a66

6 years agoMerge pull request dotnet/corefx#30556 from weshaggard/MoveToNCA3
Wes Haggard [Thu, 21 Jun 2018 15:38:10 +0000 (08:38 -0700)]
Merge pull request dotnet/corefx#30556 from weshaggard/MoveToNCA3

Move to netcoreapp3.0

Commit migrated from https://github.com/dotnet/corefx/commit/998f8f54c01f03fa57242cd8a7e8a1aab5e13a5a

6 years agoC++ cleanups and native code formatting (dotnet/corefx#30495)
kasper3 [Thu, 21 Jun 2018 14:40:29 +0000 (17:40 +0300)]
C++ cleanups and native code formatting (dotnet/corefx#30495)

* Remove C++ residue

* Unify typedef and enum stylings

* Clang 6.0 fixes

* Set CMake language to C to skip CXX compiler search

* Set visibility for Brotli APIs

Commit migrated from https://github.com/dotnet/corefx/commit/44e5bdafb8d989a220c9cf1b94f31a64a6e4f052

6 years agoAdd concurrent access detection tests to Dictionary<TKey, TValue> (dotnet/corefx...
Marco Rossignoli [Thu, 21 Jun 2018 11:28:24 +0000 (13:28 +0200)]
Add concurrent access detection tests to Dictionary<TKey, TValue> (dotnet/corefx#30515)

* add concurrent access detection tests

* add remove overloads

* simplify tests

* address PR feedback

* remove var

* nit extraline

* move comparison into same line

* cleanup unuseful instance

* cleanup typo

* improve readability

* address PR feedback

* Comment

* Access modifier

* enable removes tests

Commit migrated from https://github.com/dotnet/corefx/commit/24b9efcd1344949f4bbbf66b9b41e38d4c5271a2

6 years agoSimplify interop for AdjustTokenPrivileges (dotnet/corefx#30539)
Jan Kotas [Thu, 21 Jun 2018 04:43:14 +0000 (21:43 -0700)]
Simplify interop for AdjustTokenPrivileges (dotnet/corefx#30539)

Contributes to https://github.com/dotnet/corert/issues/5961

Commit migrated from https://github.com/dotnet/corefx/commit/9f315ae25337b2028e840dff205171843973a732

6 years agoAdd support for importing/exporting asymmetric key formats
Jeremy Barton [Thu, 21 Jun 2018 04:37:09 +0000 (21:37 -0700)]
Add support for importing/exporting asymmetric key formats

This adds support for SubjectPublicKeyInfo, PrivateKeyInfo (PKCS8) and
EncryptedPrivateKeyInfo (PKCS8) to AsymmetricAlgorithm, and adds support
for RSAPublicKey/RSAPrivateKey to RSA, and ECPrivateKey to the ECC types.

The input data to these methods is BER encoded.  PEM/Base64 values must be
converted by the caller to the BER format.

Encrypted keys can be read provided they were encrypted under RFC 2898 PBES1,
RFC 7292 PKCS12-PBE, or RFC 2898 PBES2 (with PBKDF2 as the KDF).

New keys can be encrypted using PKCS12-PBE 3DES+SHA1 (for Windows
native interop support), or PBES2 with AES.

During the development of this change it was noticed that S.S.C.Algorithms
did not build with asserts enabled, so a small portion of this change is fixing
bad asserts written during the time that they were not running.

The CNG types defer to the native layer for PKCS8 operations, partially
because CNG makes use of attributes in the PrivateKeyInfo during import
and export (at least for ECDSA), and partially because CNG has a distinction
of exportable (encrypted) vs plaintext-exportable (not).  The other platforms
currently just use the base class implementation, which utilizes the existing
ImportParameters and ExportParameters methods.

ECC keys are limited to named curves, based on RFC guidance.  Explicit
curve support can be added when needed.

Commit migrated from https://github.com/dotnet/corefx/commit/9173a573d4db1db39fcb829bf5449f07042987e0

6 years agoUpdate CoreClr, CoreFx to preview1-26621-01, preview1-26621-01, respectively (dotnet...
dotnet-maestro-bot [Thu, 21 Jun 2018 03:39:20 +0000 (20:39 -0700)]
Update CoreClr, CoreFx to preview1-26621-01, preview1-26621-01, respectively (dotnet/corefx#30568)

Commit migrated from https://github.com/dotnet/corefx/commit/2d6445746abca968cd8d04011daa259c59cc351a

6 years agoUpdate BuildTools, CoreSetup to preview1-02920-01, preview1-26620-03, respectively...
dotnet-maestro-bot [Thu, 21 Jun 2018 00:34:34 +0000 (17:34 -0700)]
Update BuildTools, CoreSetup to preview1-02920-01, preview1-26620-03, respectively (dotnet/corefx#30566)

Commit migrated from https://github.com/dotnet/corefx/commit/b8d5af6e203be0fe094ffe7858273af8351f2161

6 years agoUpdate XUnit Console Runner (dotnet/corefx#30567)
Andon Andonov [Thu, 21 Jun 2018 00:25:57 +0000 (17:25 -0700)]
Update XUnit Console Runner (dotnet/corefx#30567)

Commit migrated from https://github.com/dotnet/corefx/commit/60d51a682ed103bcdcad1dffc04e96b18de6c476

6 years agoAdd netcoreapp3.0 to frameworks for package testing
Wes Haggard [Wed, 20 Jun 2018 23:43:33 +0000 (16:43 -0700)]
Add netcoreapp3.0 to frameworks for package testing

Commit migrated from https://github.com/dotnet/corefx/commit/7918a042891ba12680619eb710ec7a1bad16e25f

6 years agoUpdate unix-instructions.md
Maryam Ariyan [Wed, 20 Jun 2018 22:27:30 +0000 (15:27 -0700)]
Update unix-instructions.md

Commit migrated from https://github.com/dotnet/corefx/commit/8fbe6c35a44be619fdce8dbca85e9273ac5bfc86

6 years agoadd long as that is what FreeBSD uses for rlimit (dotnet/corefx#30564)
Tomas Weinfurt [Wed, 20 Jun 2018 22:02:34 +0000 (15:02 -0700)]
add long as that is what FreeBSD uses for rlimit (dotnet/corefx#30564)

Commit migrated from https://github.com/dotnet/corefx/commit/4be79663da8ff9f96cd6e3f1d2215132f09c4c59

6 years agoMove packages to 3.0.0 to match NETCore app version
Wes Haggard [Wed, 20 Jun 2018 21:48:04 +0000 (14:48 -0700)]
Move packages to 3.0.0 to match NETCore app version

Commit migrated from https://github.com/dotnet/corefx/commit/fdd041b9a271e62c0aa7a1b5486f526bb70fbc23

6 years agoMerge pull request dotnet/corefx#30533 from ericstj/Reflection.TypeExtensions.harvest
Eric StJohn [Wed, 20 Jun 2018 21:07:20 +0000 (14:07 -0700)]
Merge pull request dotnet/corefx#30533 from ericstj/Reflection.TypeExtensions.harvest

Don't move System.Reflection.TypeExtensions during harvesting

Commit migrated from https://github.com/dotnet/corefx/commit/f1b08bbda7aac04452e0f02da282199c752e285c

6 years agoTests for dotnet/corefx#30263 fix (dotnet/corefx#30374)
Jeremy Kuhne [Wed, 20 Jun 2018 17:40:13 +0000 (10:40 -0700)]
Tests for dotnet/corefx#30263 fix (dotnet/corefx#30374)

* Tests for dotnet/corefx#30263 fix

Goes with https://github.com/dotnet/coreclr/pull/18460

* Add case for `C:\` to `D:\`

Commit migrated from https://github.com/dotnet/corefx/commit/eb4bb7ff28d639dcd9fd0c505d78c6196a569f57

6 years agoMove to netcoreapp3.0
Wes Haggard [Wed, 20 Jun 2018 17:07:31 +0000 (10:07 -0700)]
Move to netcoreapp3.0

Commit migrated from https://github.com/dotnet/corefx/commit/7e103021ccfe3376ebe31d81698d5fbc7e1669b8

6 years agoUpdate .NET Core SDK to 2.1.300 (dotnet/corefx#30555)
Eric Erhardt [Wed, 20 Jun 2018 17:05:43 +0000 (12:05 -0500)]
Update .NET Core SDK to 2.1.300 (dotnet/corefx#30555)

Commit migrated from https://github.com/dotnet/corefx/commit/52be753e9f5076ba2bedf473cf600b2cbc5473ef

6 years agoDon't move System.Reflection.TypeExtensions during harvesting
Eric St. John [Tue, 19 Jun 2018 22:05:00 +0000 (15:05 -0700)]
Don't move System.Reflection.TypeExtensions during harvesting

When building the netcoreapp2.0 version of the package we needed
to move the netstandard1.5 asset since it was actually netcoreapp1.0
specific.

After we shipped this version of the package, the netstandard1.5
asset was a not supported asset.  We should have stopped moving it
at this point, and instead harvest the previously moved asset
from netcoreapp1.0.

We didn't do this, so we must harvest from the last package which
contained the asset.  We can remove this workaround once the latest
stable package has the fix.

Commit migrated from https://github.com/dotnet/corefx/commit/cf1ce699bfd8a6081b6c703cc71d137cd93301c1

6 years agoFix CacheControlHeaderValue's rendering of negative values (dotnet/corefx#30554)
Stephen Toub [Wed, 20 Jun 2018 16:51:11 +0000 (12:51 -0400)]
Fix CacheControlHeaderValue's rendering of negative values (dotnet/corefx#30554)

Yesterday I made an optimization in several places to avoid unnecessary Int32.ToString calls / string allocations.  Most of them were valid.  However, even though valid Cache-Control headers don't contain negative values and are properly caught by the parser parsing incoming headers, the setters on CacheControlHeaderValue allow negative values to be specified without validation.  If such negative values were used, my change made it so that in a culture where the current culture's NumberFormatInfo.NegativeSign is not "-", the wrong negative sign would be used when rendering.  This commit fixes that and adds a regression test.

Commit migrated from https://github.com/dotnet/corefx/commit/cea9971b75665f0c9d1c3f254c4fa8c58c7d494a

6 years agoCopy CoreLib (and respective PDBs) to IL and NI folders (dotnet/corefx#30304)
Paulo Janotti [Wed, 20 Jun 2018 16:36:50 +0000 (09:36 -0700)]
Copy CoreLib (and respective PDBs) to IL and NI folders (dotnet/corefx#30304)

These are needed to workaround some OpenCover issues and to use IL rewrite tools.

Commit migrated from https://github.com/dotnet/corefx/commit/0b73ecb649230b127674465c2ca523c6ce5c3ad2

6 years agoUpdate CoreClr, CoreFx, CoreSetup to preview1-26620-04, preview1-26620-03, preview1...
dotnet-maestro-bot [Wed, 20 Jun 2018 15:46:34 +0000 (08:46 -0700)]
Update CoreClr, CoreFx, CoreSetup to preview1-26620-04, preview1-26620-03, preview1-26620-01, respectively (dotnet/corefx#30549)

Commit migrated from https://github.com/dotnet/corefx/commit/7227f8eec06b4c72363af07113e0b512fcffdccb

6 years agoUpdate Tizen CI docker image (tizen-rootfs-5.0m1) (dotnet/corefx#30480)
JongHeonChoi [Wed, 20 Jun 2018 13:10:04 +0000 (22:10 +0900)]
Update Tizen CI docker image (tizen-rootfs-5.0m1) (dotnet/corefx#30480)

* Update arm32_ci_script.sh

* Update arm32_ci_script.sh

* Update arm32_ci_script.sh

Commit migrated from https://github.com/dotnet/corefx/commit/735a35b2fe6c2384491a6ee0d1325420fa182a42

6 years agoUpdate CoreClr, CoreFx, ProjectNTfs, ProjectNTfsTestILC to preview1-26620-01, preview...
dotnet-maestro-bot [Wed, 20 Jun 2018 12:05:03 +0000 (05:05 -0700)]
Update CoreClr, CoreFx, ProjectNTfs, ProjectNTfsTestILC to preview1-26620-01, preview1-26620-01, beta-26620-00, beta-26620-00, respectively (dotnet/corefx#30537)

Commit migrated from https://github.com/dotnet/corefx/commit/3be10b6d7054b974d8343870ce13ab3f31e9ec31

6 years ago Convert System.Native to C (dotnet/corefx#30431)
kasper3 [Wed, 20 Jun 2018 00:51:17 +0000 (03:51 +0300)]
 Convert System.Native to C  (dotnet/corefx#30431)

* Rename .cpp to .c

* Convert System.Native to C

* Address feedback

Commit migrated from https://github.com/dotnet/corefx/commit/9f00f554483802a1ac295ad6260557fb125e0b31

6 years agoUse string.Create instead of StringBuilder in BitVector32.ToString (dotnet/corefx...
Stephen Toub [Wed, 20 Jun 2018 00:20:13 +0000 (20:20 -0400)]
Use string.Create instead of StringBuilder in BitVector32.ToString (dotnet/corefx#30528)

Removes the StringBuilder and underlying char[] allocation, and just writes directly into the resulting string.

Commit migrated from https://github.com/dotnet/corefx/commit/f3eec7957dd1a98901bea52aa9cbde9f75d5bde2

6 years agoUpdate area ownerships
Karel Zikmund [Tue, 19 Jun 2018 23:42:29 +0000 (16:42 -0700)]
Update area ownerships

Commit migrated from https://github.com/dotnet/corefx/commit/c7f7b5bc2f5801b598eb58ec2d25e5094bc910ba

6 years agoRemove string allocation from IPAddress.ToString/TryFormat (dotnet/corefx#30530)
Stephen Toub [Tue, 19 Jun 2018 22:58:30 +0000 (18:58 -0400)]
Remove string allocation from IPAddress.ToString/TryFormat (dotnet/corefx#30530)

IPv6 addresses with embedded IPv4 addresses were incurring an extra string allocation for the IPv4 address.

Commit migrated from https://github.com/dotnet/corefx/commit/83abd139edc4e2aa810c9fafe8c69e9d8dd9ad10

6 years agoClarify output size handling
Jeremy Barton [Tue, 19 Jun 2018 22:41:42 +0000 (15:41 -0700)]
Clarify output size handling

Commit migrated from https://github.com/dotnet/corefx/commit/d1bc30c2afefa4777f5539f65776095c49740b28

6 years agoRemove more number ToStrings from System.Net.Http headers (dotnet/corefx#30529)
Stephen Toub [Tue, 19 Jun 2018 21:34:55 +0000 (17:34 -0400)]
Remove more number ToStrings from System.Net.Http headers (dotnet/corefx#30529)

Previously these wouldn't have helped but also wouldn't really have hurt. However, now that StringBuilder doesn't call ToString() by default on numeric types, these are resulting in unnecessary string allocations.

Commit migrated from https://github.com/dotnet/corefx/commit/36ab1b5c1e503235e7c9100490de39ce73fe46e6

6 years agoRemove StringBuilderCache usage from System.Text.RegularExpressions (dotnet/corefx...
Viktor Hofer [Tue, 19 Jun 2018 21:34:37 +0000 (23:34 +0200)]
Remove StringBuilderCache usage from System.Text.RegularExpressions (dotnet/corefx#30474)

* Remove StringBuilderCache usage

* fixed buffer size, manual reverse copying & local textinfo

* Fast path for not to encode string

* avoid one span slice

* code formatting & bounds check opt

* Avoid string allocation in char class

Commit migrated from https://github.com/dotnet/corefx/commit/33f401f5a8f7d78d18e96e33cdaf3da84f9b8438

6 years agoRemove some allocations from SocketAddress.ToString (dotnet/corefx#30521)
Stephen Toub [Tue, 19 Jun 2018 20:57:48 +0000 (16:57 -0400)]
Remove some allocations from SocketAddress.ToString (dotnet/corefx#30521)

* Remove some allocations from SocketAddress.ToString

Avoids a string allocation per byte, plus a few other intermediary strings.

* Disable failing SocketAddress.ToString test on Unix

Commit migrated from https://github.com/dotnet/corefx/commit/e910a045e63ce87f8218e62091e0806336039874

6 years agoRemove string allocation from Uri.PathDifference (dotnet/corefx#30514)
Stephen Toub [Tue, 19 Jun 2018 20:55:54 +0000 (16:55 -0400)]
Remove string allocation from Uri.PathDifference (dotnet/corefx#30514)

Commit migrated from https://github.com/dotnet/corefx/commit/e1756ebbacffe3d0238ee9299908b10cebcd5a7e

6 years agoRemove a few boxing allocations from SecurityIdentifier.ToString (dotnet/corefx#30512)
Stephen Toub [Tue, 19 Jun 2018 20:55:36 +0000 (16:55 -0400)]
Remove a few boxing allocations from SecurityIdentifier.ToString (dotnet/corefx#30512)

Commit migrated from https://github.com/dotnet/corefx/commit/9b3717bbc85fd17ac3481fc96365b092834dc637

6 years agoRemove unnecessary DllImports from System.Drawing.Common (dotnet/corefx#30510)
Stephen Toub [Tue, 19 Jun 2018 20:54:54 +0000 (16:54 -0400)]
Remove unnecessary DllImports from System.Drawing.Common (dotnet/corefx#30510)

Commit migrated from https://github.com/dotnet/corefx/commit/4a3c31a8dab92ab48bc44179944f72f5b26eb6e7

6 years agoRemove StringBuilder in System.IO.Pipes marshaling (dotnet/corefx#30509)
Stephen Toub [Tue, 19 Jun 2018 20:53:41 +0000 (16:53 -0400)]
Remove StringBuilder in System.IO.Pipes marshaling (dotnet/corefx#30509)

* Remove StringBuilder in System.IO.Pipes marshaling

To get the impersonated user name, we can just stackalloc space for the Win32 call and then create a string from that, instead of allocating a StringBuilder and its underlying char[], paying the associated StringBuilder marshaling costs, and then creating the string from that.

* Fix existing typo in comment

Commit migrated from https://github.com/dotnet/corefx/commit/c09a2a5296d444b1e7e9b5fe659d2fdd4e742d79

6 years agoRemove some StringBuilder-related allocations from System.Net.Http (dotnet/corefx...
Stephen Toub [Tue, 19 Jun 2018 20:51:58 +0000 (16:51 -0400)]
Remove some StringBuilder-related allocations from System.Net.Http (dotnet/corefx#30508)

* Remove boxing and ToString allocations from RangeHeaderValue.ToString

The current code uses ToString(object), boxng the long? and then calling ToString on it.  By instead first checking whether the value is null and only calling ToString(long), we avoid both the box and the string allocations, for both From and To, relying on StringBuilder's ability to format a long directly into its buffer.

* Avoid StringBuilder/char[]/string allocation/copy in DumpHeaders

We can just write into the existing StringBuilder rather than creating a new one, appending to that, copying it to a string, and then appending that string to the original.

Commit migrated from https://github.com/dotnet/corefx/commit/8c0487bfeff9229beca93dc480028b83d8e39705

6 years agoAdding support for synchronous Ping (dotnet/corefx#30000)
Tony Di Nucci [Tue, 19 Jun 2018 20:49:07 +0000 (21:49 +0100)]
Adding support for synchronous Ping (dotnet/corefx#30000)

* Adding support for synchronous Ping

* Address PR feedback

* Address additional feedback

* Missed 2nd commented out visibility modifier

* Fix build for UWP

* Remove use of deprecated property

* Refactor to remove need for unsafe block

* Remove redundant calls to Stopwatch.Stop()

* Revert to using IPAddress.Address rather than IPAddress.GetAddressBytes() for IPv4

Commit migrated from https://github.com/dotnet/corefx/commit/3ed92c4e3b21ec09787eeb79788cf41fc1280889

6 years agoMake the Linux TLS hostname comparison be case-insensitive
Jeremy Barton [Tue, 19 Jun 2018 20:09:42 +0000 (13:09 -0700)]
Make the Linux TLS hostname comparison be case-insensitive

This change also adds direct tests to CheckX509Hostname, because we still haven't added a strong X509Extension subclass for Subject Alternative Name, which is where more direct exposure would live.

Commit migrated from https://github.com/dotnet/corefx/commit/237ab14caf7e60f221e5d1d0103477f99c17509d

6 years agoUpdate BuildTools, CoreClr, CoreSetup to preview1-02919-01, preview1-26619-04, previe...
dotnet-maestro-bot [Tue, 19 Jun 2018 19:53:30 +0000 (12:53 -0700)]
Update BuildTools, CoreClr, CoreSetup to preview1-02919-01, preview1-26619-04, preview1-26619-03, respectively (dotnet/corefx#30524)

Commit migrated from https://github.com/dotnet/corefx/commit/8999b95fdd189440c2f1c6a914bad4adaa6be090

6 years agoEnsure Reflection.Context tests find the correct results. (dotnet/corefx#30519)
Eric Erhardt [Tue, 19 Jun 2018 18:29:18 +0000 (13:29 -0500)]
Ensure Reflection.Context tests find the correct results. (dotnet/corefx#30519)

Assert.All on an empty collection will pass.

Also, update the .resx message to mention which test requires the resource.

Commit migrated from https://github.com/dotnet/corefx/commit/e2aec459cd3dadab0edde0e3666edfe47a277514

6 years agoExpose and add unit tests for ISOWeek (dotnet/corefx#30386)
Kristian Hellang [Tue, 19 Jun 2018 16:17:03 +0000 (18:17 +0200)]
Expose and add unit tests for ISOWeek (dotnet/corefx#30386)

* Expose ISOWeek in System.Globalization

* Add unit tests for ISOWeek

* PR Feedback

* Add ISOWeek to ApiCompatBaseline

* Added more edge-case tests

Commit migrated from https://github.com/dotnet/corefx/commit/9ed08bb062d6d73391dfd3c3bb812b090537772e

6 years agoRemove unused method from System.Text.Encoding.CodePages
Stephen Toub [Tue, 19 Jun 2018 14:56:29 +0000 (10:56 -0400)]
Remove unused method from System.Text.Encoding.CodePages

Commit migrated from https://github.com/dotnet/corefx/commit/7d772b56e070ff20ca0508e9d978f200b91a02c0

6 years agoMerge pull request dotnet/corefx#30497 from dotnet-maestro-bot/master-UpdateDependencies
Jan Kotas [Tue, 19 Jun 2018 13:01:24 +0000 (06:01 -0700)]
Merge pull request dotnet/corefx#30497 from dotnet-maestro-bot/master-UpdateDependencies

Update BuildTools, CoreClr, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview1-02918-02, preview1-26619-01, preview1-26618-02, beta-26619-00, beta-26619-00, respectively (master)

Commit migrated from https://github.com/dotnet/corefx/commit/fe7adb2bf92bba926268c2e9f562b11c84932a07

6 years agoImprove Intel hardware intrinsic APIs
Fei Peng [Fri, 15 Jun 2018 02:14:44 +0000 (19:14 -0700)]
Improve Intel hardware intrinsic APIs

Commit migrated from https://github.com/dotnet/corefx/commit/9027f4da59d858bab422ca319e53a85d85b73f72

6 years agoUpdate BuildTools, CoreClr, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview1...
dotnet-maestro-bot [Tue, 19 Jun 2018 05:15:53 +0000 (22:15 -0700)]
Update BuildTools, CoreClr, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to preview1-02918-02, preview1-26619-01, preview1-26618-02, beta-26619-00, beta-26619-00, respectively

Commit migrated from https://github.com/dotnet/corefx/commit/9cc7583caec9befd2e80ec1c684fadc4b3a78bba

6 years agoFix SocketsHttpHandler for Windows auth proxy CONNECT tunneling (dotnet/corefx#30478)
David Shulman [Mon, 18 Jun 2018 23:21:44 +0000 (16:21 -0700)]
Fix SocketsHttpHandler for Windows auth proxy CONNECT tunneling (dotnet/corefx#30478)

SocketsHttpHandler wasn't even trying to send Negotiate/NTLM auth tokens to a proxy. This was due
to some invalid logic regarding the "usingProxy" field in HttpConnection. Reworked this logic to
be clearer about the various kinds of proxy scenarios.

I refactored the loopback proxy server and made it much more robust. It can now handle multiple
requests and multiple connections which helps test against the other handlers whose behavior is
different in this area. I plan to do further work in consolidating the LoopbackServer and
LoopbackProxyServer classes in future PRs.

I created a separate HttpClientHandlerTest.Proxy.cs file and moved many existing proxy tests and
added new tests. The current HttpClientHandlerTest.cs file is still over 3000 lines and needs more
refactoring to make it easier to maintain and track test scenario coverage.

Fixes dotnet/corefx#30330

Commit migrated from https://github.com/dotnet/corefx/commit/ec1671fd7feffe1070a94d9d86379e0dd95ddcdf

6 years agoExpose and Add tests for StringBuilder overloads of TextWriter (dotnet/corefx#30491)
Vance Morrison [Mon, 18 Jun 2018 23:00:42 +0000 (16:00 -0700)]
Expose and Add tests for StringBuilder overloads of TextWriter (dotnet/corefx#30491)

* Expose and Add tests for StringBuilder overloads of TextWriter

Add tests for implementation in https://github.com/dotnet/coreclr/pull/18281
This supports the issue https://github.com/dotnet/corefx/issues/30048

* Remove empty line

* Added tests for empy and large strings for the Text.Write*(StringBuilder) APIs

* Add AppCompat overrides for UWP.

(lost in merge conflict)

* review feedback

Commit migrated from https://github.com/dotnet/corefx/commit/7e4093b9787b54da5329e5f752c34f42610c9e39

6 years agoRemove multiplication in pal_networking.c (dotnet/corefx#30496)
Stephen Toub [Mon, 18 Jun 2018 20:51:01 +0000 (16:51 -0400)]
Remove multiplication in pal_networking.c (dotnet/corefx#30496)

* Remove multiplication in pal_networking.c

* Fix paren

Commit migrated from https://github.com/dotnet/corefx/commit/16f1fe20e3d6c68cc77325d3f30b1dbbca417920

6 years agoCross compile compat pack shims against 2.0 and use the 2.1 inbox ones (dotnet/corefx...
Santiago Fernandez Madero [Mon, 18 Jun 2018 18:24:07 +0000 (11:24 -0700)]
Cross compile compat pack shims against 2.0 and use the 2.1 inbox ones (dotnet/corefx#30031)

* Cross compile compat pack shims against 2.0 and use the 2.1 inbox ones

* Fix build issues and use shims.proj produced facades as ref assemblies in the package

* Exclude System.ValueTuple only on nca2.0 and break compat pack dependency on shims package

* PR Feedback

* PR Feedback

Commit migrated from https://github.com/dotnet/corefx/commit/d73434c0a8a6d7eb4f11d23c408d9f3d2ff809c4

6 years agoAdd test for dotnet/corefx#29914 (dotnet/corefx#30408)
Krzysztof Wicher [Mon, 18 Jun 2018 16:17:45 +0000 (09:17 -0700)]
Add test for dotnet/corefx#29914 (dotnet/corefx#30408)

Commit migrated from https://github.com/dotnet/corefx/commit/21e73c6b703946032a61cd639c2ba7662b319785

6 years agoUpdate ProjectNTfs, ProjectNTfsTestILC to beta-26618-00, beta-26618-00, respectively...
dotnet-maestro-bot [Mon, 18 Jun 2018 16:17:00 +0000 (09:17 -0700)]
Update ProjectNTfs, ProjectNTfsTestILC to beta-26618-00, beta-26618-00, respectively (dotnet/corefx#30481)

Commit migrated from https://github.com/dotnet/corefx/commit/803e0b33cc2ce2a1d42391b79424b0f1fd07aa2d

6 years agoAdd support for concatenated GZip streams. (dotnet/corefx#30442)
Ian Hays [Mon, 18 Jun 2018 15:59:41 +0000 (08:59 -0700)]
Add support for concatenated GZip streams. (dotnet/corefx#30442)

Currently, if you pass two or more concatenated GZipStreams we will read into the second one (to fill a buffer) but not do anything with that information. This PR modifies the Inflater code to instead look at the appended data for the Gzip header magic bytes and treats the rest of the data stream as an additional data segment if they are found.

More info:
- There is no limit to the number of concatenated GZipStreams supported.
- If a GZipStream is appended with garbage that happens to have its first two bytes equal to the GZip header bytes, then an exception will result. This is an acceptable risk, as garbage appended to a valid GZipStream isn't really usable right now anyways since we read past the end of the first stream into that data to fill our input buffer.
- Added exhaustive tests to test buffer boundary behavior
- Concatenated streams are supported using Read, ReadAsync, CopyTo, etc.

Commit migrated from https://github.com/dotnet/corefx/commit/55f2293ddda3c972fcc2d94915b03bc8556e8c9b

6 years agoSockets on Windows: reduce array allocations during Select, Poll, Receive, Send ...
Marc Gravell [Mon, 18 Jun 2018 15:56:46 +0000 (16:56 +0100)]
Sockets on Windows: reduce array allocations during Select, Poll, Receive, Send (dotnet/corefx#30485)

* untested; zero allocs during Socket.Poll and Socket.Select on Windows (aveat: Socket.Select with > cutoff will still allocate)

* use MemoryMarshal.GetReference - cleanly passes null ref for empty span

* remove all the "unsafe"; pretty sure that the "ref" will count as a "fixed" during the P/Invoke

* avoid allocating in Socket.Send/Socket.Receive when passing multiple segments (synchronous API)

* Revert "avoid allocating in Socket.Send/Socket.Receive when passing multiple segments (synchronous API)"

This reverts commit dotnet/corefx@343b88602bd7974f64ae8247f5415b6bf590a89b.

* use spans for multi-segment sync send/receive

* remove "unsafe" from select - no longer required

* fix nit whitespace

* address @stephentoub feedback from review:

- prefer Foo* to ref Foo in p/invoke
- avoid repeated .Count access
- use const size stackalloc instead of dynamic
- use ArrayPool instead of allocate
- avoid multiple testing of count when determining stack vs heap
- use smaller stack threshold

* add debug assertions to express intent of file descriptor size vs socket list size

* use slice+span.clear to simplify objectsToPin wipe

Commit migrated from https://github.com/dotnet/corefx/commit/146fe58389624354fee8e48ffffc2fde1c2e89f9

6 years agoConvert System.Security.Cryptography.Native to C (dotnet/corefx#30376)
kasper3 [Mon, 18 Jun 2018 15:56:18 +0000 (18:56 +0300)]
Convert System.Security.Cryptography.Native to C (dotnet/corefx#30376)

* Rename extension .cpp to .c

* Convert System.Security.Cryptography.Native to C

* Address feedback comments

Commit migrated from https://github.com/dotnet/corefx/commit/30148bf4a56ea5dc934893f8b87367ff221014a6

6 years agoAdd Path.Join string overloads (dotnet/corefx#30447)
Marco Rossignoli [Mon, 18 Jun 2018 15:53:25 +0000 (17:53 +0200)]
Add Path.Join string overloads (dotnet/corefx#30447)

* update tests

* add null tests

* add null tests

* added uapaot ApiCompatBaseline

Commit migrated from https://github.com/dotnet/corefx/commit/2776b6373590a896833b8b0eec4446f22f502ab0

6 years agoExposing CallerArgumentExpressionAttribute from System.Runtime assembly (dotnet/coref...
jswolf19 [Mon, 18 Jun 2018 15:53:06 +0000 (00:53 +0900)]
Exposing CallerArgumentExpressionAttribute from System.Runtime assembly (dotnet/corefx#30469)

* Expose CallerArgumentExpressionAttribute (dotnet/corefx#21809)

* added basic CallerArgumentExpressionAttribute tests

* added test to show that overload without optional parameter is taken over method with

* added tests to illustrate behavior of CallerArgumentExpressionAttribute (final behavior may differ)

* added type CallerArgumentExpressionAttribute to uapaot ApiCompatBaseline

* Moved CallerArgumentExpressionTests to non-netfx section

* added newlines as per review

Commit migrated from https://github.com/dotnet/corefx/commit/a9e5ed00dbc1aa662342e7e51ac1dc137941a91e

6 years ago Convert S.S.Cryptography.Native.Apple to C (dotnet/corefx#30448)
kasper3 [Mon, 18 Jun 2018 15:52:28 +0000 (18:52 +0300)]
 Convert S.S.Cryptography.Native.Apple to C (dotnet/corefx#30448)

* Rename extension .cpp to .c

* Convert S.S.Cryptography.Native.Apple to C

* Use memset instead of consts for zero-init

Commit migrated from https://github.com/dotnet/corefx/commit/9908dee27b7a73046c8dae4a1db1b3603e795c8a

6 years agoUpper-case a const in IPAddress
Stephen Toub [Mon, 18 Jun 2018 15:04:54 +0000 (11:04 -0400)]
Upper-case a const in IPAddress

Commit migrated from https://github.com/dotnet/corefx/commit/f6c6a894bd5b385636d4db778cd3ce6bf09daca3

6 years agoAdd some more CodeDom tests (dotnet/corefx#30387)
Hugh Bellamy [Mon, 18 Jun 2018 14:14:28 +0000 (15:14 +0100)]
Add some more CodeDom tests (dotnet/corefx#30387)

* Cleanup some CodeDom product code

* Cleanup CodeDom tests

* Add misc CodeDom tests

* Address PR feedback

* Fix netfx tests

Commit migrated from https://github.com/dotnet/corefx/commit/ac70bb1294a0fad6cacb4523ee057b7ffcd3a42b

6 years agoReenable tests for fixed ProjectN bug (dotnet/corefx#30467)
Jan Kotas [Sun, 17 Jun 2018 12:55:28 +0000 (05:55 -0700)]
Reenable tests for fixed ProjectN bug (dotnet/corefx#30467)

The bug has been fixed in ProjectN 3 years ago.

Fixes dotnet/corefx#16747
Fixes dotnet/corefx#21198

Commit migrated from https://github.com/dotnet/corefx/commit/7303e22416dbcf4c27940efa90770d183f9162dc