mono.git
7 years ago[profiler] Actually link against libmono where necessary (#3232)
Aleksey Kliger (λgeek) [Tue, 5 Jul 2016 14:21:55 +0000 (10:21 -0400)]
[profiler] Actually link against libmono where necessary (#3232)

Previously $(LIBMONO) was empty and bitcode targets (which set
-no-undefined) had linker errors.

7 years agoMerge pull request #3226 from esdrubal/soap_headers_fix
Marcos Henrich [Tue, 5 Jul 2016 10:31:14 +0000 (11:31 +0100)]
Merge pull request #3226 from esdrubal/soap_headers_fix

[System.Web.Services] Fixes bad XmlMapping.Key.

7 years agoMerge pull request #3210 from esdrubal/connectasyncUHE
Marcos Henrich [Tue, 5 Jul 2016 09:46:03 +0000 (10:46 +0100)]
Merge pull request #3210 from esdrubal/connectasyncUHE

[System] Fixes ConnectAsync UnhandledEx

7 years agoMerge pull request #2958 from kumpera/visibility
Rodrigo Kumpera [Mon, 4 Jul 2016 19:46:33 +0000 (15:46 -0400)]
Merge pull request #2958 from kumpera/visibility

Fix a visibility check bug

7 years ago[mcs] More tweaks in betterness improvements. Fixes #42057
Marek Safar [Mon, 4 Jul 2016 13:01:00 +0000 (15:01 +0200)]
[mcs] More tweaks in betterness improvements. Fixes #42057

7 years agoMerge pull request #3234 from tritao/zip_non_seekable_streams
João Matos [Mon, 4 Jul 2016 11:10:51 +0000 (12:10 +0100)]
Merge pull request #3234 from tritao/zip_non_seekable_streams

[System.IO.Compression] Fixes ZipArchive to support non-seekable streams

7 years ago[System.Numerics.Vectors] Update type forwarders
Marek Safar [Mon, 4 Jul 2016 10:39:42 +0000 (12:39 +0200)]
[System.Numerics.Vectors] Update type forwarders

7 years ago[System.Numerics] Update .net 4.6 api
Marek Safar [Mon, 4 Jul 2016 09:23:23 +0000 (11:23 +0200)]
[System.Numerics] Update .net 4.6 api

7 years ago[runtime] Implement TLS_OP_GET_REG on linux (#3227)
Alexander Kyte [Sun, 3 Jul 2016 00:26:04 +0000 (20:26 -0400)]
[runtime] Implement TLS_OP_GET_REG on linux (#3227)

7 years ago[runtime] Abort the finalizer thread first instead of stopping it, to allow an orderl...
Zoltan Varga [Sun, 3 Jul 2016 00:25:06 +0000 (20:25 -0400)]
[runtime] Abort the finalizer thread first instead of stopping it, to allow an orderly shutdown and to avoid hitting the 'finalizer_thread_exited' assert. Hopefully fixes #41833. (#3233)

7 years ago[System.IO.Compression] Fixes ZipArchive to support non-seekable streams.
João Matos [Sat, 2 Jul 2016 01:02:25 +0000 (02:02 +0100)]
[System.IO.Compression] Fixes ZipArchive to support non-seekable streams.

This is the same behavior as documented on MSDN.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=30686.

7 years ago[verifier] Do method visibility checks for virtual final methods. Enable type visibil...
Rodrigo Kumpera [Fri, 1 Jul 2016 23:57:07 +0000 (19:57 -0400)]
[verifier] Do method visibility checks for virtual final methods. Enable type visibility for all methods. Fixes #5644.

I addressed the issue mentioned in the comments of mono_method_can_access_method:

* FIXME:
* with generics calls to explicit interface implementations can be expressed
* directly: the method is private, but we must allow it. This may be opening
* a hole or the generics code should handle this differently.
* Maybe just ensure the interface type is public.

The way to do it is to check access between gmds

7 years agoMerge pull request #3211 from BrzVlad/fix-finalizer-thread-exited
Vlad Brezae [Fri, 1 Jul 2016 20:56:31 +0000 (23:56 +0300)]
Merge pull request #3211 from BrzVlad/fix-finalizer-thread-exited

[sgen] Speed up domain finalization at shutdown

7 years ago[remoting] If remoting is disabled, don't assert looking for LoadRemoteFieldNew ...
Aleksey Kliger (λgeek) [Fri, 1 Jul 2016 15:11:54 +0000 (11:11 -0400)]
[remoting] If remoting is disabled, don't assert looking for LoadRemoteFieldNew (#3229)

7 years ago[sgen] Make suspend_finalizers volatile
Vlad Brezae [Fri, 1 Jul 2016 15:10:01 +0000 (18:10 +0300)]
[sgen] Make suspend_finalizers volatile

It is used for signaling on separate threads.

7 years agoMerge pull request #3225 from tritao/zip_stream_getters
João Matos [Fri, 1 Jul 2016 14:05:57 +0000 (15:05 +0100)]
Merge pull request #3225 from tritao/zip_stream_getters

[System.IO.Compression] Fixed Zip entry stream length/position getters in Update mode

7 years ago[llvmonly] Fix the name of a few llvmonly icalls.
Zoltan Varga [Fri, 1 Jul 2016 02:42:51 +0000 (22:42 -0400)]
[llvmonly] Fix the name of a few llvmonly icalls.

7 years ago[llvmonly] Unwrap RuntimeWrapperExceptions if needed.
Zoltan Varga [Fri, 1 Jul 2016 02:31:07 +0000 (22:31 -0400)]
[llvmonly] Unwrap RuntimeWrapperExceptions if needed.

7 years ago[sgen] Avoid throwing exceptions from inside the critical region in the managed alloc...
Zoltan Varga [Fri, 1 Jul 2016 02:28:55 +0000 (22:28 -0400)]
[sgen] Avoid throwing exceptions from inside the critical region in the managed allocators. (#3230)

7 years ago[corlib] Mark some StackTrace/StackFrame methods as NoInlining to prevent llvm from...
Zoltan Varga [Fri, 1 Jul 2016 02:07:54 +0000 (22:07 -0400)]
[corlib] Mark some StackTrace/StackFrame methods as NoInlining to prevent llvm from inlining these methods, which breaks the stacktrace computation code in the runtime.

7 years ago[tests] Probe for a different type than System.IO.Pipes.PipeOptions which is not...
Zoltan Varga [Fri, 1 Jul 2016 01:15:05 +0000 (21:15 -0400)]
[tests] Probe for a different type than System.IO.Pipes.PipeOptions which is not part of the mobile_static profile. Fixes #41955.

7 years ago[llvmonly] Avoid asserting when caching non-open generic instances.
Zoltan Varga [Fri, 1 Jul 2016 00:49:17 +0000 (20:49 -0400)]
[llvmonly] Avoid asserting when caching non-open generic instances.

7 years ago[llvmonly] Emit gsharedvt wrappers for Nullable.Unbox calls.
Zoltan Varga [Fri, 1 Jul 2016 00:48:42 +0000 (20:48 -0400)]
[llvmonly] Emit gsharedvt wrappers for Nullable.Unbox calls.

7 years ago[llvmonly] Fix a case where an ftnptr was invoked as a method address.
Zoltan Varga [Fri, 1 Jul 2016 00:35:26 +0000 (20:35 -0400)]
[llvmonly] Fix a case where an ftnptr was invoked as a method address.

7 years ago[llvmonly] Fix invocation of string ctors. Emit Array.Set/Get wrappers for more types.
Zoltan Varga [Thu, 30 Jun 2016 23:34:50 +0000 (19:34 -0400)]
[llvmonly] Fix invocation of string ctors. Emit Array.Set/Get wrappers for more types.

7 years ago[jit] Avoid emitting seq points inside alloc wrappers, they contain critical regions...
Zoltan Varga [Thu, 30 Jun 2016 21:40:18 +0000 (17:40 -0400)]
[jit] Avoid emitting seq points inside alloc wrappers, they contain critical regions, and if thread self suspend in the seq point handler, it cannot be suspended by other threads. Fixes #42191.

7 years ago[System.Web.Services] Fixes bad XmlMapping.Key.
Marcos Henrich [Thu, 30 Jun 2016 16:59:21 +0000 (17:59 +0100)]
[System.Web.Services] Fixes bad XmlMapping.Key.

Fixes #41564

Calling xmlImporter.ImportMembersMapping would set the key with the
underlying message type [1], thus if a service had remote calls using
the same types a key already exists exception would be thrown.

Furthermore reference source has special logic to set headers
XmlMappings key [2].

This pull request fixes the issue by overriding the XmlMappings.Key with
the values similar to those used in the reference source version.

[1] http://referencesource.microsoft.com/#System.Xml/System/Xml/Serialization/XmlMembersMapping.cs,28
[2] http://referencesource.microsoft.com/#System.Web.Services/System/Web/Services/Protocols/SoapReflector.cs,515

7 years ago[System.Web.Services] Test Header sharing issue.
Marcos Henrich [Thu, 30 Jun 2016 12:42:42 +0000 (13:42 +0100)]
[System.Web.Services] Test Header sharing issue.

Covers #41564

When multiple methods shared soap header a duplicate key exception would
be thrown.

This issue only occurs on XAMMAC and MOBILE where the non reference
source serializer is still used.

7 years agoRestore NULL check which PR #3040/#3105 mistakenly removed (bug 41623) (#3219)
Andi McClure [Thu, 30 Jun 2016 16:44:46 +0000 (12:44 -0400)]
Restore NULL check which PR #3040/#3105 mistakenly removed (bug 41623) (#3219)

Could cause crash while stepping over in SDB.

7 years ago[System.IO.Compression] Fixed Zip entry stream length/position getters in Update...
João Matos [Thu, 30 Jun 2016 12:58:27 +0000 (13:58 +0100)]
[System.IO.Compression] Fixed Zip entry stream length/position getters in Update mode.

This does away with the lazy writeable entry scheme in Update mode and converts the stream to be writeable when its opened in Update mode.

From local testing, .NET does the same in this case.

Fixes another issue reported by @Numpsy in https://github.com/OfficeDev/Open-XML-SDK/issues/64.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=42274.

7 years agoMerge pull request #3216 from tritao/zip_duplicate_entries
João Matos [Thu, 30 Jun 2016 11:58:00 +0000 (12:58 +0100)]
Merge pull request #3216 from tritao/zip_duplicate_entries

[System.IO.Compression] Fixed handling of Zip archives with duplicate entries with same name.

7 years ago[runtime] Document MonoDomain.static_data_array. (#3223)
Jon Purdy [Thu, 30 Jun 2016 07:00:36 +0000 (00:00 -0700)]
[runtime] Document MonoDomain.static_data_array. (#3223)

Saw a confusing comment, updated it.

7 years agoMerge pull request #3220 from alexrp/master
Alex Rønne Petersen [Thu, 30 Jun 2016 02:08:28 +0000 (04:08 +0200)]
Merge pull request #3220 from alexrp/master

Revert changes to profiler library linking

7 years agoRevert "[profiler] Don't build shared libraries under bitcode."
Alex Rønne Petersen [Wed, 29 Jun 2016 22:44:20 +0000 (00:44 +0200)]
Revert "[profiler] Don't build shared libraries under bitcode."

This reverts commit cfd9870f8345d2e3e6354e3deebced443809ee2f.

There is no need for this as of 79b99a989d8d4cf2636b738a623bb3656e048ebf.

7 years ago[profiler] Link profiler libraries against libmono (revert of 92341a).
Alex Rønne Petersen [Wed, 29 Jun 2016 22:41:43 +0000 (00:41 +0200)]
[profiler] Link profiler libraries against libmono (revert of 92341a).

This caused issues with symbol resolution at runtime on Android and we haven't
seen any *actual* cases where linking against libmono caused problems.

7 years ago[bcl] Add a workaround for a watchos limitation to a memory mapped file test. Fixes...
Zoltan Varga [Wed, 29 Jun 2016 13:39:37 +0000 (09:39 -0400)]
[bcl] Add a workaround for a watchos limitation to a memory mapped file test. Fixes #41747.

7 years ago[System.IO.Compression] Fixed handling of Zip archives with duplicate entries with...
João Matos [Wed, 29 Jun 2016 10:18:16 +0000 (11:18 +0100)]
[System.IO.Compression] Fixed handling of Zip archives with duplicate entries with same name.

.NET supports this, from MSDN: "If an entry with the specified path and name already exists in the archive, a second entry is created with the same path and name.".

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=42219.

7 years agoMerge pull request #3214 from tritao/zip_new_entries_writes
João Matos [Wed, 29 Jun 2016 10:20:44 +0000 (11:20 +0100)]
Merge pull request #3214 from tritao/zip_new_entries_writes

[System.IO.Compression] Fixed writes to newly-created Zip archive entries in Update mode.

7 years ago[remoting] Convert mono_load_remote_field_new_checked to managed code (#3149)
Aleksey Kliger (λgeek) [Tue, 28 Jun 2016 22:22:04 +0000 (18:22 -0400)]
[remoting] Convert mono_load_remote_field_new_checked to managed code (#3149)

* [remoting] Convert mono_load_remote_field_new_checked to managed code.

* [corlib] Expose runtime struct MonoRemoteClass and MonoClass to managed

Also expose  mono_class_get_type to managed code.

* [corlib] Add Mono.RuntimeClassHandle to encapsulate MonoClass*

and Mono.RuntimeRemoteClassHandle to encapsulate MonoRemoteClass*

* [runtime] mono_marshal_get_ldfld_remote_wrapper invoke the managed TransparentProxy.LoadRemoteFieldNew method directly

Don't bother going through a native call and back out to managed.

* [runtime] Get rid of MONO_WRAPPER_LDFLD_REMOTE

When the MONO_WRAPPER_LDFLD is operating on a proxy, it always invokes
the TransparentProxy::LoadRemoteFieldNew managed method

* [runtime] Remove dead mono_load_remote_field_new_icall

* [mini] Bump AOT file format version

Because we removed the LDFLD_REMOTE wrapper type so all the
MonoWrapperType enum values shifted.

7 years agoMerge pull request #3187 from akoeplinger/mstestsuite-on-prs
Alexander Köplinger [Tue, 28 Jun 2016 19:35:42 +0000 (21:35 +0200)]
Merge pull request #3187 from akoeplinger/mstestsuite-on-prs

[ci] Add ms-test-suite step to default test runs

7 years ago[ci] Skip ms-test-suite on non-OSX workers
Alexander Köplinger [Tue, 28 Jun 2016 17:48:45 +0000 (19:48 +0200)]
[ci] Skip ms-test-suite on non-OSX workers

Some locale tests are running into issues on Linux, they should be investigated separately.

7 years ago[System.IO.Compression] Fixed writes to newly-created Zip archive entries in Update...
João Matos [Tue, 28 Jun 2016 16:54:13 +0000 (17:54 +0100)]
[System.IO.Compression] Fixed writes to newly-created Zip archive entries in Update mode.

This regression was reported by RichardW of Open XML SDK project.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=39282.

7 years agoMerge pull request #3204 from BrzVlad/fix-lock-free-alloc2
monojenkins [Mon, 27 Jun 2016 23:08:47 +0000 (00:08 +0100)]
Merge pull request #3204 from BrzVlad/fix-lock-free-alloc2

[utils] Fix retiring of live block for the lock free allocator

Freeing a block descriptor (along with the block) can happen either when freeing a pointer in the block (we do this in order to prevent situations where we need to wait for the next alloc in order to free a block), either when we acquire an empty block while allocating. Either way, in order to free a block descriptor, we need to acquire it first.

When freeing a slot in a block, we are checking if the block is now empty in which case we acquire the block descriptor in order to free it (along with the block). While doing so, we were failing to account for the case where, by the time we make the block descriptor empty and the time we acquire it, another thread would try to allocate from the same descriptor, see that it's empty, free it, allocate a new descriptor (which would happen to have the same address as the retired one) to fulfill the allocation and then set it as the active descriptor for the allocator. When the first thread finally acquires the descriptor, we need to double check that it is still empty since it might be logically a different descriptor than the one we actually freed from. In the unlikely case it's not empty, we need to put it back in the allocator's data structures.

7 years ago[sgen] Use sgen_qsort instead of qsort (#3205)
Vlad Brezae [Mon, 27 Jun 2016 16:30:45 +0000 (19:30 +0300)]
[sgen] Use sgen_qsort instead of qsort (#3205)

qsort is not signal safe.

7 years agoMerge pull request #3202 from dlahoti/patch-1
Alexander Köplinger [Mon, 27 Jun 2016 11:07:08 +0000 (13:07 +0200)]
Merge pull request #3202 from dlahoti/patch-1

make monodis exit with value 1 on an error

7 years ago[System] Fixes ConnectAsync UnhandledEx
Marcos Henrich [Mon, 27 Jun 2016 09:00:01 +0000 (10:00 +0100)]
[System] Fixes ConnectAsync UnhandledEx

Fixes #41616

ConnectAsyncCallback now throws an exception when called a second time.
ConnectAsync reuses SocketAsyncEventArgs in BeginConnect which
already updates its state and calls ConnectAsyncCallback.

The changes make sure that ConnectAsyncCallback no longer called on
ConnectAsync catch block, while the state is still updated with the
exception.

7 years ago[System] Test Unhandled Ex on ConnectAsync
Marcos Henrich [Mon, 27 Jun 2016 08:50:48 +0000 (09:50 +0100)]
[System] Test Unhandled Ex on ConnectAsync

Covers #41616

Our console runner is currently swallowing this test unhandled
exceptions.

To make it test show the failure I had to set legacyUnhandledExceptionPolicy
to 0 in mcs/class/lib/net_4_x/nunit-console.exe.config

Then running we can observe the crash by running:
make -C mcs/class/System check TESTNAME=System.Net.Sockets.SocketTest.ConnectAsyncUnhandledEx

Other tests appear to crash with legacyUEP set to 0, while the runner
shows no errors.

7 years ago[sgen] Speed up domain finalization at shutdown
Vlad Brezae [Mon, 27 Jun 2016 14:31:50 +0000 (17:31 +0300)]
[sgen] Speed up domain finalization at shutdown

When we cleanup the gc at shutdown, we no longer care about running the remaining finalizers so we set the suspend_finalizers flag. This flag skipped running the finalizers but we would still traverse and modify the sgen finalizer hashes (on an arm box this could take even longer than 1s and lead to finalizer_thread_exited assertion failure since it's over the 100ms limit).

Avoid traversing sgen finalization hashes as soon as we see that we are shutting down.

7 years agoMerge pull request #3209 from tritao/master
João Matos [Fri, 24 Jun 2016 19:25:09 +0000 (20:25 +0100)]
Merge pull request #3209 from tritao/master

[System.IO.Compression] Fixed stream writes when Zip archive is opened in Update mode

7 years agoMerge pull request #3208 from ludovic-henry/iolayer-remove-shared
Ludovic Henry [Fri, 24 Jun 2016 17:23:30 +0000 (19:23 +0200)]
Merge pull request #3208 from ludovic-henry/iolayer-remove-shared

[io-layer] Remove remaining pieces for cross-process mutex, semaphore and event

7 years agoEnhanced logging - attempt 2.5 (#3191)
Neale Ferguson [Fri, 24 Jun 2016 16:47:01 +0000 (12:47 -0400)]
Enhanced logging - attempt 2.5 (#3191)

* Revert "Revert "Enhance log tracing""

This reverts commit 565c6ac0802eedf68755bd5776c80b00ab388415.

* Better handle legacy log handler processing with suggestions from lamdageek

* Remove unnecessary assignment

* Restore mono_trace_set_log_handler parameters to their original specification

7 years ago[io-layer] Replace remaining pthread_cond_t by mono_cond_t
Ludovic Henry [Fri, 24 Jun 2016 13:46:15 +0000 (15:46 +0200)]
[io-layer] Replace remaining pthread_cond_t by mono_cond_t

7 years ago[io-layer] Fix potential buffer overrun
Ludovic Henry [Fri, 24 Jun 2016 13:43:17 +0000 (15:43 +0200)]
[io-layer] Fix potential buffer overrun

7 years ago[io-layer] Remove _wapi_shared_layout
Ludovic Henry [Fri, 24 Jun 2016 13:30:47 +0000 (15:30 +0200)]
[io-layer] Remove _wapi_shared_layout

This effectively remove any remaining code regarding the cross-process sharing of certain io-layer facilities.

7 years ago[System.IO.Compression] Fixed stream writes when Zip archive is opened in Update...
João Matos [Fri, 24 Jun 2016 00:12:33 +0000 (01:12 +0100)]
[System.IO.Compression] Fixed stream writes when Zip archive is opened in Update mode.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=39282.

Also helps with https://github.com/OfficeDev/Open-XML-SDK/issues/64.

7 years agoMerge pull request #3207 from ntherning/fix_broken_libmonosgen_dll_on_cygwin
Alexander Köplinger [Thu, 23 Jun 2016 22:37:04 +0000 (00:37 +0200)]
Merge pull request #3207 from ntherning/fix_broken_libmonosgen_dll_on_cygwin

Fix broken libmonosgen-2.0.dll on Cygwin due to -ggdb3 flag in CFLAGS

7 years ago[io-layer] Merge _WapiHandleShared type into _WapiHandleUnshared
Ludovic Henry [Thu, 23 Jun 2016 11:36:06 +0000 (13:36 +0200)]
[io-layer] Merge _WapiHandleShared type into _WapiHandleUnshared

7 years ago[io-layer] Make shared and unshared handle have the same fields
Ludovic Henry [Thu, 23 Jun 2016 11:27:17 +0000 (13:27 +0200)]
[io-layer] Make shared and unshared handle have the same fields

7 years ago[io-layer] Remove mutex and namedmutex pid field
Ludovic Henry [Thu, 23 Jun 2016 11:25:32 +0000 (13:25 +0200)]
[io-layer] Remove mutex and namedmutex pid field

We do not support shared process handles anymore, so the pid is always going to be the same

7 years ago[io-layer] Remove _wapi_handle_timedwait_signal
Ludovic Henry [Thu, 23 Jun 2016 10:03:32 +0000 (12:03 +0200)]
[io-layer] Remove _wapi_handle_timedwait_signal

7 years agoDon't pass -ggdb3 in CFLAGS on Windows builds as it somehow corrupts the
Niklas Therning [Thu, 23 Jun 2016 12:27:01 +0000 (14:27 +0200)]
Don't pass -ggdb3 in CFLAGS on Windows builds as it somehow corrupts the
libmonosgen-2.0.dll and breaks the build of monograph.exe which links against
it.

Also adds -O2 to CFLAGS on all platforms to align with how releases are built.

7 years agomake monodis exit with value 1 on an error
dlahoti [Thu, 23 Jun 2016 04:24:25 +0000 (23:24 -0500)]
make monodis exit with value 1 on an error

This should make it easier to programmatically check for errors, since it will remove the need to test the output string, which is an unreliable way of doing things.

7 years ago[utils] Fix retiring of live block for the lock free allocator
Vlad Brezae [Thu, 16 Jun 2016 09:07:06 +0000 (12:07 +0300)]
[utils] Fix retiring of live block for the lock free allocator

Freeing a block descriptor (along with the block) can happen either when freeing a pointer in the block (we do this in order to prevent situations where we need to wait for the next alloc in order to free a block), either when we acquire an empty block while allocating. Either way, in order to free a block descriptor, we need to acquire it first.

When freeing a slot in a block, we are checking if the block is now empty in which case we acquire the block descriptor in order to free it (along with the block). While doing so, we were failing to account for the case where, by the time we make the block descriptor empty and the time we acquire it, another thread would try to allocate from the same descriptor, see that it's empty, free it, allocate a new descriptor (which would happen to have the same address as the retired one) to fulfill the allocation and then set it as the active descriptor for the allocator. When the first thread finally acquires the descriptor, we need to double check that it is still empty since it might be logically a different descriptor than the one we actually freed from. In the unlikely case it's not empty, we need to put it back in the allocator's data structures.

7 years ago[runtime] Bump corlib version for recent Thread layout changes
Vlad Brezae [Wed, 22 Jun 2016 14:43:31 +0000 (17:43 +0300)]
[runtime] Bump corlib version for recent Thread layout changes

7 years agoMerge pull request #3197 from BrzVlad/fix-thread-layout
Alexander Köplinger [Wed, 22 Jun 2016 22:35:18 +0000 (00:35 +0200)]
Merge pull request #3197 from BrzVlad/fix-thread-layout

[sgen] Fix Thread layout after changes in #3123

7 years agoDon't run the ping test on certain Android devices
Marek Habersack [Wed, 22 Jun 2016 12:42:51 +0000 (14:42 +0200)]
Don't run the ping test on certain Android devices

As described in https://bugzilla.xamarin.com/show_bug.cgi?id=34883 at
least Samsung SG3 doesn't allow access to the local network
interface (in fact, even ifconfig doesn't work on the device). Therefore
the test needs to be disabled on those devices. This is the first part
of the fix, the second one will be implemented in Xamarin.Android test
suite which will provide the AndroidShouldPingWork method which will
check the device id against list of those that do not work for this
test.

Part #1 of fix for https://bugzilla.xamarin.com/show_bug.cgi?id=34883

7 years ago[sgen] Fix Thread layout after changes in #3123
Vlad Brezae [Wed, 22 Jun 2016 09:17:22 +0000 (12:17 +0300)]
[sgen] Fix Thread layout after changes in #3123

7 years agoMerge pull request #3195 from tritao/zip_stream_getters
João Matos [Tue, 21 Jun 2016 23:52:27 +0000 (00:52 +0100)]
Merge pull request #3195 from tritao/zip_stream_getters

[System.IO.Compression] Fixed stream length/position getters for ZIP entries

7 years ago[System.IO.Compression] Fixed stream length/position getters for ZIP entries.
João Matos [Tue, 21 Jun 2016 22:59:03 +0000 (23:59 +0100)]
[System.IO.Compression] Fixed stream length/position getters for ZIP entries.

Partial fix for https://bugzilla.xamarin.com/show_bug.cgi?id=39282.

Partial fix for https://github.com/OfficeDev/Open-XML-SDK/issues/64.

7 years ago[System] Overwrite Console encoding to match mcs text output for CodeDOM compiler...
Marek Safar [Tue, 21 Jun 2016 17:44:05 +0000 (19:44 +0200)]
[System] Overwrite Console encoding to match mcs text output for CodeDOM compiler. Fixes #41979

7 years agoMerge pull request #3188 from akoeplinger/mozroots-fix
Alexander Köplinger [Tue, 21 Jun 2016 15:15:57 +0000 (17:15 +0200)]
Merge pull request #3188 from akoeplinger/mozroots-fix

[tools] Fix mozroots URL for Mozilla's certdata.txt and add deprecation warning

7 years ago[tools] Fix mozroots URL for Mozilla's certdata.txt and add deprecation warning
Alexander Köplinger [Mon, 20 Jun 2016 14:49:35 +0000 (16:49 +0200)]
[tools] Fix mozroots URL for Mozilla's certdata.txt and add deprecation warning

MXR is not coming back (see https://bugzilla.mozilla.org/show_bug.cgi?id=1279952 and https://github.com/SuaveIO/mono-script-buildpack/issues/9#issuecomment-226749314)
and this broke everyone who still relied on mozroots. Fix by using the version from the hg repository instead.

Starting from Mono 3.12 we've been shipping cert-sync to import CA certificates from the local computer trust store to Mono's trust store,
we strongly encourage everyone to move to that instead. Added a deprecation warning to mozroots to further strengthen this message.

Note that when fetching the CA list over the new https URL we need to skip cert validation errors, as the common use case for mozroots is when
no certs are present on the system (bootstrapping). This enables MITM but we don't really have any other options. Another reason why cert-sync is superior.

7 years ago[System] Update IPInterfaceProperties initialization on windows. Fixes #41897
Marek Safar [Tue, 21 Jun 2016 13:50:02 +0000 (15:50 +0200)]
[System] Update IPInterfaceProperties initialization on windows. Fixes #41897

7 years ago[corlib] Add range check for minimal date in dst calculation. Fixes #41667
Marek Safar [Tue, 21 Jun 2016 13:15:12 +0000 (15:15 +0200)]
[corlib] Add range check for minimal date in dst calculation. Fixes #41667

7 years ago[scripts/submodules] Add branch to check if fetch is needed
Alexander Köplinger [Tue, 21 Jun 2016 01:03:07 +0000 (03:03 +0200)]
[scripts/submodules] Add branch to check if fetch is needed

In some cases the "git log -1 <remote>" check fails even though the remote is configured
and an unnecessary fetch is done. Adding the branch to the check fixes this.

7 years agoUse thread priority at thread start time (#3123)
Neale Ferguson [Mon, 20 Jun 2016 14:26:51 +0000 (10:26 -0400)]
Use thread priority at thread start time (#3123)

* An enhancement to the thread priority work added earlier. This will support starting a thread with a specified priority. Currently, the thread will start with the priority of the creator. The semantics of threads allow you to specify the priority of a thread before it has started. Therefore, we take note of this value at thread creation time.

* Missed committing this file the first time

* Correct typo

* Fix creation_flags reference

* MonoThreadParm really should not be in objects-internal

* Place priority in MonoInternalThread where it can be accessed by GetThreadPriority(). This enablses the priority to be set/retrieved before the thread is started. It also ensures that new threads default to a priority of THREAD_PRIORITY_NORMAL rather than inheriting the parent thread's priority.

* Revert changes to MonoInternalThread/Thread.cs. Properly use the handle for thread lookup. Initialize priority at thread creation time. Use stored value of priority if thread has not been started.

* Add code to handle retrieving the thread priority from a started thread that had been set before thread had started. This is necessary as before the thread is started the priority value can be manipulated. This value is stored in the MonoThread structure. Before the thread is started the value can be interrogated so we return this value rather than invoking the GetThreadPriority() API. When a thread is started this value is used to set the threads priority (if scheduling policy is SCHED_FIFO or SCHED_RR). For POSIX threads, after the thread is started we now keep the priority in the _Wapi_thread structure which is located via the thread handle. This structure doesn't exist until after the thread is started so we can't store the value there but after we can cache the priority value there and return it for non-SCHED_[RR|FIFO] threads. This way the expected value will always be set and returned by ThreadPriority property (currently for these threads it will simply return Normal). A test case has been added to the mono/tests directory.

* Use a copy of creation_flags so local modifications aren't propagated

* Use pthread_setschedparam as OSX doesn't support pthread_setschedprio

7 years ago[reflection] Improves 1a820fcdc09b8f72d12a0973e25db7acc434d0cc to do vslot match...
Marek Safar [Mon, 20 Jun 2016 11:42:02 +0000 (13:42 +0200)]
[reflection] Improves 1a820fcdc09b8f72d12a0973e25db7acc434d0cc to do vslot match as optimization only

7 years agoMerge pull request #3179 from gttds/patch-2
Alexander Köplinger [Mon, 20 Jun 2016 11:33:59 +0000 (13:33 +0200)]
Merge pull request #3179 from gttds/patch-2

[System.Web] Fixes 50 year form authentication

7 years agoMerge pull request #3184 from tritao/zip_datetime
João Matos [Mon, 20 Jun 2016 11:18:12 +0000 (12:18 +0100)]
Merge pull request #3184 from tritao/zip_datetime

[System.IO.Compression] Fixed Zip entries with unset last write time to return the same as .NET.

7 years ago[ci] Add ms-test-suite step to default test runs
Alexander Köplinger [Mon, 20 Jun 2016 11:00:54 +0000 (13:00 +0200)]
[ci] Add ms-test-suite step to default test runs

7 years agoMerge pull request #3183 from marek-safar/bug41874
Marek Safar [Mon, 20 Jun 2016 09:44:42 +0000 (11:44 +0200)]
Merge pull request #3183 from marek-safar/bug41874

[reflection] Properties always use name and signature hidding rules. …

7 years ago[System.Web] Fixes SkinID property declaration
Marek Safar [Mon, 20 Jun 2016 09:33:07 +0000 (11:33 +0200)]
[System.Web] Fixes SkinID property declaration

7 years ago[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947.
Zoltan Varga [Fri, 17 Jun 2016 21:26:47 +0000 (17:26 -0400)]
[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947.

7 years agoRevert "[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947."
Zoltan Varga [Sat, 18 Jun 2016 20:16:43 +0000 (16:16 -0400)]
Revert "[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947."

This reverts commit 4cbef26bb7878187c8bd3a0029e711331e6e4510.

Revert this to see if it fixes the windows build.

7 years ago[runtime] Don't call ExecutionEngine constructor in aot mode (#3185)
Alexander Kyte [Sat, 18 Jun 2016 17:12:15 +0000 (13:12 -0400)]
[runtime] Don't call ExecutionEngine constructor in aot mode (#3185)

7 years ago[aot] Add support for array accessor methods for multi-dimensional arrays. Fixes...
Zoltan Varga [Sat, 18 Jun 2016 00:46:26 +0000 (20:46 -0400)]
[aot] Add support for array accessor methods for multi-dimensional arrays. Fixes #41937.

7 years ago[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947.
Zoltan Varga [Fri, 17 Jun 2016 21:26:47 +0000 (17:26 -0400)]
[llvm] Fix the allocation of vregs for the OP_MIN/MAX opcodes. Fixes #41947.

7 years ago[System.IO.Compression] Fixed Zip entries with unset last write time to return the...
João Matos [Fri, 17 Jun 2016 17:19:19 +0000 (18:19 +0100)]
[System.IO.Compression] Fixed Zip entries with unset last write time to return the same as .NET.

.NET on Windows returns a fixed date for this, replicate the same behaviour in Mono.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=40916.

See also: https://github.com/NuGet/Home/issues/2518

7 years ago[reflection] Properties always use name and signature hidding rules. Fixes #41874
Marek Safar [Fri, 17 Jun 2016 16:44:45 +0000 (18:44 +0200)]
[reflection] Properties always use name and signature hidding rules. Fixes #41874

7 years agoFix for x86 and amd64 continuations (#3182)
Dunati [Fri, 17 Jun 2016 02:15:14 +0000 (19:15 -0700)]
Fix for x86 and amd64 continuations (#3182)

7 years ago[aot] Fix leaking a MonoError.
Zoltan Varga [Thu, 16 Jun 2016 23:07:22 +0000 (19:07 -0400)]
[aot] Fix leaking a MonoError.

7 years ago[aot] Avoid asserting if loading a type fails.
Zoltan Varga [Thu, 16 Jun 2016 23:04:27 +0000 (19:04 -0400)]
[aot] Avoid asserting if loading a type fails.

7 years agoMerge pull request #3163 from alexanderkyte/fast_context_clean
Bernhard Urban [Thu, 16 Jun 2016 18:51:59 +0000 (11:51 -0700)]
Merge pull request #3163 from alexanderkyte/fast_context_clean

[runtime] Store abremoval context statuses seperately to use memset for cleanup

7 years ago[bcl] Remove cosmetic target that always triggers a rebuild (#3180)
Alexander Kyte [Thu, 16 Jun 2016 18:51:31 +0000 (14:51 -0400)]
[bcl] Remove cosmetic target that always triggers a rebuild (#3180)

7 years agoMerge pull request #3175 from marek-safar/cas-cleanup
Marek Safar [Thu, 16 Jun 2016 18:35:13 +0000 (20:35 +0200)]
Merge pull request #3175 from marek-safar/cas-cleanup

[bcl] Make mono cas opt-in features instead of opt-out for mobile pro…

7 years ago[System.Web] Fixes 50 year form authentication
gttds [Thu, 16 Jun 2016 15:46:21 +0000 (23:46 +0800)]
[System.Web] Fixes 50 year form authentication

This fixes the bug where form authentication tickets do not expire until 50 years later.
I bumped into this bug after upgrading mono from 4.2.2 to 4.4.0

Firstly, the authentication ticket's expiry must always equal to the timeout attribute on the <forms/> element. It doesn't matter whether persistent or session cookies are used.

Secondly, if the cookie is persistent, then it's expiry should be set to the same as that of the authentication ticket.

Reference: https://blogs.msdn.microsoft.com/dansellers/2006/02/15/change-to-asp-net-2-0-forms-authentication-persistent-cookies/

7 years ago[System] Put back handling of direct ip addresses to ServicePoint::HostEntry (removed...
Marek Safar [Thu, 16 Jun 2016 15:42:55 +0000 (17:42 +0200)]
[System] Put back handling of direct ip addresses to ServicePoint::HostEntry (removed in 932359f3d627da13408350b1172ceb63c30f6327). Fixes #41782

7 years ago[runtime] Return early so mono_value_box_checked doesn't clobber error (#3172)
Alexander Kyte [Thu, 16 Jun 2016 15:18:19 +0000 (11:18 -0400)]
[runtime] Return early so mono_value_box_checked doesn't clobber error (#3172)

7 years ago[runtime] Store abremoval context statuses seperately to use memset for cleanup
Alexander Kyte [Fri, 10 Jun 2016 18:14:36 +0000 (14:14 -0400)]
[runtime] Store abremoval context statuses seperately to use memset for cleanup

7 years ago[bcl] Make mono cas opt-in features instead of opt-out for mobile profiles
Marek Safar [Thu, 16 Jun 2016 08:16:10 +0000 (10:16 +0200)]
[bcl] Make mono cas opt-in features instead of opt-out for mobile profiles