Commit Graph
211 Commits
Author SHA1 Message Date
Gonzalo Paniagua Javier e497bb1b59 2010-07-06 Gonzalo Paniagua Javier <[email protected]>
* Process.cs: allow the exit callback to be used more than once. Fixes
	bug #614909.



svn path=/trunk/mcs/; revision=159980
2010-07-06 18:39:07 +00:00
Gonzalo Paniagua Javier 9b948ac91d 2010-07-04 Gonzalo Paniagua Javier <[email protected]>
* Process.cs: ignore processes that finish while we are looking for
	processes by name. Fixes bug #596779.


svn path=/trunk/mcs/; revision=159866
2010-07-04 21:31:42 +00:00
Jb Evain e5cb263033 2010-04-06 Jb Evain <[email protected]>
* Debug.cs: make class static.


svn path=/trunk/mcs/; revision=154843
2010-04-06 12:49:51 +00:00
Jb Evain 85f02eb1ed 2010-04-06 Jb Evain <[email protected]>
* Debug.cs (Assert, WriteLine): add net_4_0 overloads.


svn path=/trunk/mcs/; revision=154842
2010-04-06 12:48:27 +00:00
Sebastien Pouliot dd1802b725 In System.Diagnostics:
2010-03-11  Sebastien Pouliot  <[email protected]>

	* Debug_2_1.cs: Change type to static to match SL4

In .:
2010-03-11  Sebastien Pouliot  <[email protected]>

	* net_2_1_raw_System.dll.sources: Add existing files that are 
	part of SL4

In System.Collections.Generic:
2010-03-11  Sebastien Pouliot  <[email protected]>

	* ISet.cs: Add NET_2_1 since this is part of SL4


svn path=/trunk/mcs/; revision=153477
2010-03-11 18:15:05 +00:00
Gonzalo Paniagua Javier bbc13e42bc 2010-01-27 Gonzalo Paniagua Javier <[email protected]>
* Stopwatch.cs: add new Restart().


svn path=/trunk/mcs/; revision=150317
2010-01-27 22:40:18 +00:00
Sebastien Pouliot 300fca4fd3 2009-11-30 Sebastien Pouliot <[email protected]>
* Debug_2_1.cs: Change type to sealed to match SL2/3


svn path=/trunk/mcs/; revision=147153
2009-12-01 01:14:35 +00:00
Zoltan Varga bcd2356726 2009-10-12 Zoltan Varga <[email protected]>
* Process.cs (Dispose): Close the async output/error readers. Fixes #545429.

svn path=/trunk/mcs/; revision=143985
2009-10-12 21:28:49 +00:00
Jb Evain 44d5cd6772 2009-07-22 Jb Evain <[email protected]>
* ProcessStartInfo.cs: force no-verb on MONOTOUCH.


svn path=/trunk/mcs/; revision=138407
2009-07-22 14:19:51 +00:00
Gonzalo Paniagua Javier fbdb064a75 2009-07-10 Gonzalo Paniagua Javier <[email protected]>
* ProcessStartInfo.cs: HaveEnvVars is enabled by just using the
	EnvironmentVariables property. Bug #520650 fixed.


svn path=/trunk/mcs/; revision=137730
2009-07-10 20:54:29 +00:00
Jonathan Pryor 3b6088ff92 * System.Diagnostics/DiagnosticsConfigurationHandler.cs: Use the new
TraceSourceInfo(string, SourceLevels, TraceImplSettings) constructor.
	* System.Diagnostics/TraceSourceInfo.cs: Add a new constructor, 
	  TraceSourceInfo(string, SourceLevels, TraceImplSettings), which adds
	  the DefaultTraceListener w/o depending upon (the possibly still
	  initializing) TraceImpl members.  Fixes #502944.
	* Test/test-config-file: Add a /configuration/system.diagnostics/source
	  section to elicit the buggy behavior found in #502944.

svn path=/trunk/mcs/; revision=133981
2009-05-12 18:53:16 +00:00
Jonathan Pryor f80c179df7 * DiagnosticsConfigurationHandler.cs: Don't refer to TraceImpl member
while reading the .config file, instead cache the values and refer
	  to the cached values during initialization.  This prevents recursive
	  initialization calls (Trace.OnInit() ... Trace.Listeners.Add() ...
	  Trace.OnInit() ...), and associated duplicate parsing of .config file
	  sections.  Fixes bnc#499442.
	* TraceImpl.cs: Cope with DiagnosticsConfigurationHandler changes.
	* TraceListenerCollection.cs: Add internal 
	  Add(TraceListener,TraceImplSettings) method for adding
	  TraceListeners during DiagnosticsConfigurationHandler initialization
	  (which can't access TraceImpl, as we may still be reading the
	  .config file to determine the TraceImpl values).

svn path=/trunk/mcs/; revision=133291
2009-05-01 20:21:50 +00:00
Gonzalo Paniagua Javier e4d01de353 2009-04-28 Gonzalo Paniagua Javier <[email protected]>
* ConsoleTraceListener.cs: add an internal constructor that takes a
	string argument. Used when 'initializeData' is set.
	* DiagnosticsConfigurationHandler.cs: try internal constructors when
	the assembly is System.
	Fixes bug #498853.


svn path=/trunk/mcs/; revision=132868
2009-04-28 17:47:15 +00:00
Miguel de Icaza 401337e297 2009-04-19 Miguel de Icaza <[email protected]>
* Process.cs: Do not crash if GetProcesses_internal returns null
	This happens on operating systems where we have not implemented

svn path=/trunk/mcs/; revision=132110
2009-04-20 03:57:44 +00:00
Andrés G. Aragoneses eeb713067a changelog..
svn path=/trunk/mcs/; revision=127933
2009-02-25 02:33:30 +00:00
Zoltan Varga c1b14152d3 2009-01-22 Zoltan Varga <[email protected]>
* Stopwatch.cs: Reorder the calculations in Elapsed and ElapsedMilliseconds
	to avoid overflow. Fixes #468570. Patch by Yoni Shalom <[email protected]>.

svn path=/trunk/mcs/; revision=124260
2009-01-22 22:13:31 +00:00
Zoltan Varga 10cabfadcc 2009-01-18 Zoltan Varga <[email protected]>
* Process.cs: Avoid closing the duplicated process handle in
	ProcessWaitHandle, it is done automatically by the WaitHandle.Dispose ().
	Fixes #464628.

svn path=/trunk/mcs/; revision=123738
2009-01-18 16:00:11 +00:00
Christian Hergert 79be0ac6d8 2008-12-09 Christian Hergert <[email protected]>
* System/Test/System.Diagnostics/CounterCreationDataTest.cs: Test to verify CounterHelp defaults to String.Empty.
	* System/System.Diagnostics/CounterCreationData.cs: Default CounterHelp to String.Empty.


svn path=/trunk/mcs/; revision=121172
2008-12-09 23:32:18 +00:00
Gonzalo Paniagua Javier adcaff89cc 2008-11-20 Gonzalo Paniagua Javier <[email protected]>
* PerformanceCounter.cs: add 2 workarounds for known problems. I will
	add the corresponding test cases later.


svn path=/trunk/mcs/; revision=119506
2008-11-20 20:40:55 +00:00
Bill Holmes 18e193acd5 2008-11-13 Bill Holmes <[email protected]>
* process.h : Adding method declaration for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* process.c : Adding implementation for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* icall-def.h : Registering ICALL Processs.WaitForInputIdle_internal
	  to ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* wait.h : Adding method declaration for WaitForInputIdle.

	* wait.c : Adding implementation for WaitForInputIdle.

	* Process.cs : Adding an implementation for WaitForInputIdle
	  to call the an internal call.  The internal call is only
	  implemented properly on Windows.

	Code is contributed under MIT/X11 license.


svn path=/trunk/mcs/; revision=118724
2008-11-13 16:03:48 +00:00
Jonathan Chambers 84ec87d71b 2008-11-06 Jonathan Chambers <[email protected]>
* MonoIO.cs : Add DuplicateHandle.

2008-11-06  Jonathan Chambers  <[email protected]>

        * Process.cs : Use DuplicateHandle when redirecting
        StdInput and StdOutput. Fixes bug #436291.



svn path=/trunk/mcs/; revision=118134
2008-11-06 18:48:08 +00:00
Paolo Molaro 43c05dda29 Mon Oct 13 14:39:52 CEST 2008 Paolo Molaro <[email protected]>
* Process.cs: added icall and implementation of many memory-related
	query methods (bug #434473).


svn path=/trunk/mcs/; revision=115653
2008-10-13 12:42:08 +00:00
Gert Driesen 4e89905665 * PerformanceCounter.cs:
* Stopwatch.cs:
* TraceImpl.cs: Fixed line endings.

svn path=/trunk/mcs/; revision=113630
2008-09-20 11:44:57 +00:00
Gert Driesen a21deeae6a * DiagnosticsConfigurationHandler.cs (AddTraceAttributes): Avoid
wrapping configuration errors thrown during initialization of
TraceImpl. Fixed line endings.

svn path=/trunk/mcs/; revision=113629
2008-09-20 11:41:12 +00:00
Paolo Molaro 9136ca99bd Thu Sep 18 18:14:25 CEST 2008 Paolo Molaro <[email protected]>
* CounterSampleCalculator.cs: added more calculated types.
	* PerformanceCounter.cs: NextValue() works as well as RawValue.


svn path=/trunk/mcs/; revision=113435
2008-09-18 16:16:20 +00:00
Bill Holmes 017eaee375 2008-09-10 Bill Holmes <[email protected]>
* Socket.cs : Adding a comment to provide locations where
	  changes to MonoSocketAsyncResult need to be synced.

	* Process.cs : Update the fields of ProcessAsyncReader to
	  match MonoSocketAsyncResult metadata/socket-io.h

	Code is contributed under MIT/X11 license.


svn path=/trunk/mcs/; revision=112681
2008-09-10 15:20:35 +00:00
Jonathan Pryor 6f6b608851 * TraceImpl.cs:
- Remove the "lock-free" code, which (come to think of it) would be 
	    faulty in a multithreaded environment anyway because the "other"
	    threads won't wait (block) until initialization is complete...
	  - Add InitOnce() calls to all public properties, so that
	    `Debug.AutoFlush=true' will cause InitOnce() to be loaded, lest
	    a `Debug.AutoFlush=true; Debug.Listeners.Add(...)` sequence cause
	    .AutoFlush=true to be ignored as the InitOnce implied by .Add() 
	    will "overwrite" the .AutoFlush.
	  - Split up TraceListenerCollection creation from DefaultTraceListener 
	    addition, as TraceListenerCollection.Add() calls back into 
	    TraceImpl, so if these aren't separate we get an infinite loop
	    and never actually initialize anything.
	  - Fixes #424370.
	* TraceListenerCollection.cs: Add a TraceListenerCollection(bool)
	  constructor, which provides a way to NOT add the
	  DefaultTraceListener (needed by TraceImpl; see above).

svn path=/trunk/mcs/; revision=112596
2008-09-09 15:08:29 +00:00
Sebastien Pouliot 7fb5fe021f 2008-08-06 Sebastien Pouliot <[email protected]>
* Debug_2_1.cs: Add missing [Conditional] attributes.


svn path=/trunk/mcs/; revision=109803
2008-08-06 23:52:01 +00:00
Gert Driesen 0b2a27db70 * TraceListenerTest.cs: Added test for GetSupportedAttributes.
* DelimitedTraceListener.cs: Changed accessibility of
GetSupportedAttributes to protected internal.
* DiagnosticsConfigurationHandler.cs: Use GetSupportedAttributes to
allow custom attributes on tracelisteners. Fixes bug #413203.
* TraceListener.cs: Changed accessibility of GetSupportedAttributes
to protected internal. Removed MonoTODO on GetSupportedAttributes and
Attributes. Fixed line endings.

svn path=/trunk/mcs/; revision=109500
2008-08-02 20:06:21 +00:00
Paolo Molaro b73eaaf930 Fri Aug 1 16:09:31 CEST 2008 Paolo Molaro <[email protected]>
* CounterCreationData.cs, PerformanceCounterCategory.cs: more
	checks and default type fix.


svn path=/trunk/mcs/; revision=109426
2008-08-01 14:11:15 +00:00
Dick Porter 941ac90384 2008-07-28 Dick Porter <[email protected]>
* Process.cs: When passing handle references around, it needs to
	be duplicated and freed so the OS doesn't close it.  Makes the
	testcase in 410743 work again now the underlying bug has been
	fixed.



svn path=/trunk/mcs/; revision=109048
2008-07-28 16:30:37 +00:00
Zoltan Varga eff019542d 2008-07-27 Zoltan Varga <[email protected]>
* Process.cs (SetExitCallbackIfNeeded): Avoid a race condition by not
	checking for HashExited.

svn path=/trunk/mcs/; revision=108887
2008-07-27 00:08:08 +00:00
Atsushi Eno bbd60d7cfe 2008-06-27 Atsushi Enomoto <[email protected]>
* DiagnosticsConfigurationHandler.cs: quick build fix (hopefully).


svn path=/trunk/mcs/; revision=106649
2008-06-26 16:49:15 +00:00
Gert Driesen 3ff3823088 * DiagnosticsConfigurationHandler.cs: On 2.0 profile, throw
ConfigurationErrorsException when any attribute other than 'Name'
is found when referencing a shared listener. Fixes bug #404054.
Added support for the traceOutputOptions attribute on 2.0 profile.
Fixes bug #403583.
* ConfigXmlDocument.cs: Implement IConfigErrorInfo on all Node classes.

svn path=/trunk/mcs/; revision=106628
2008-06-26 10:54:00 +00:00
Robert Jordan 2b194c193d In System.Diagnostics:
2008-06-21  Robert Jordan  <[email protected]>

	* Process.cs (Start_common): UserName may be null or empty.
	Fixes bug  #350543.

In Test/System.Diagnostics:
2008-06-21  Robert Jordan  <[email protected]>

	* ProcessTest.cs (Start_UseShellExecuteWithEmptyUserName):
	add test for bug #350543.


svn path=/trunk/mcs/; revision=106452
2008-06-23 19:09:22 +00:00
Dick Porter 91247bdd98 Fix thinko in ChangeLog
svn path=/trunk/mcs/; revision=106218
2008-06-19 14:58:06 +00:00
Dick Porter a4a491eac8 2008-06-19 Dick Porter <[email protected]>
* Process.cs: Match the buffer sizes of StreamWriter and
	MonoSyncFileStream for redirected stdout and stderr.  Fixes bug
	401225.



svn path=/trunk/mcs/; revision=106217
2008-06-19 14:56:31 +00:00
Zoltan Varga 59e4f75430 2008-05-02 Zoltan Varga <[email protected]>
* TraceImpl.cs: Update the IndentLevel property of this class when Indent ()
	or Unindent () are called. Fixes #385666.

svn path=/trunk/mcs/; revision=102370
2008-05-02 19:53:10 +00:00
Dick Porter 61df680295 2008-03-26 Dick Porter <[email protected]>
* FileVersionInfo.cs: Patch from Gert Driesen
	([email protected]) for bug 355717.



svn path=/trunk/mcs/; revision=99024
2008-03-26 12:45:56 +00:00
Zoltan Varga 398deff940 2008-03-19 Zoltan Varga <[email protected]>
* Stopwatch.cs: Fix visibility of GetTimestamp () method.

svn path=/trunk/mcs/; revision=98562
2008-03-18 23:18:41 +00:00
Paolo Molaro 2e7c11fb4f Thu Feb 28 19:52:30 CET 2008 Paolo Molaro <[email protected]>
* CounterCreationData.cs, PerformanceCounterCategory.cs,
	PerformanceCounter.cs: bugfixes, icalls for categories,
	more methods implemented.


svn path=/trunk/mcs/; revision=96911
2008-02-28 18:11:08 +00:00
Paolo Molaro d133be3585 Wed Feb 27 20:00:04 CET 2008 Paolo Molaro <[email protected]>
* CounterSample.cs, CounterSampleCalculator.cs, PerformanceCounter.cs,
	PerformanceCounterCategory.cs, PerformanceCounterCategoryType.cs:
	beginning of the performance counter implementation.


svn path=/trunk/mcs/; revision=96810
2008-02-27 18:14:57 +00:00
Paolo Molaro 40c299e777 Tue Feb 26 18:37:13 CET 2008 Paolo Molaro <[email protected]>
* Stopwatch.cs: use an hires monotonic clock.


svn path=/trunk/mcs/; revision=96667
2008-02-26 16:51:52 +00:00
Gert Driesen 3009758b4d * FileVersionInfoTest.cs: Added set of (mostly notworking) tests for
FileVersionInfo, and indirectly also for AssemblyBuilder.
* FileVersionInfo.cs (GetVersionInfo): Resolve filename to absolute
path, and throw FileNotFoundException if it does not exist.
* System_test.dll.sources: Added FileVersionInfoTest.cs.

svn path=/trunk/mcs/; revision=93643
2008-01-23 12:39:43 +00:00
Gert Driesen baab1f11d4 * Process.cs: In PriorityClass setter, first check whether value is
valid and remove LAMESPEC since the documentation has been corrected 
for .NET 3.5. Code formatting.
* ProcessTest.cs: Added tests for PriorityClass.

svn path=/trunk/mcs/; revision=91804
2007-12-22 09:48:37 +00:00
Dick Porter 6ffa6c9dbc 2007-12-19 Dick Porter <[email protected]>
* Process.cs: Check that the process has been started before
	getting or setting the priority class.  Fixes bug 348415.

2007-12-19  Dick Porter  <[email protected]>

	* Win32Exception.cs: Add text for error 5, Access denied.



svn path=/trunk/mcs/; revision=91629
2007-12-19 14:25:14 +00:00
Miguel de Icaza a69047bd6d 07-12-10 Miguel de Icaza <[email protected]>
* DefaultTraceListener.cs: By default set the AssertUiEnabled to
	false, as this is what we had previously and some broken
	applications (Tomboy) are too trigger happy with Debug.Assert. 

	Also, we now load the Windows.Forms code on demand, instead of
	preloading it on the static ctor to reduce memory usage.


svn path=/trunk/mcs/; revision=91070
2007-12-10 22:45:06 +00:00
Gert Driesen 1c14498de3 * LocalFileEventLog.cs: To allow entry to be fully written before
attempting to read it, added small sleep period in the Created event
of the FSW.

svn path=/trunk/mcs/; revision=90994
2007-12-08 16:02:41 +00:00
Gert Driesen 3b0d04fd6c * Process.cs: Modified StartInfo to throw ArgumentNullException when
value is set to null, instead of ArgumentException. Remove check if   
file name is rooted and exists when UseShellExecute is false, and let
runtime handle this. Fixes bug #345565. When a process cannot be started, do
not access ProcessStartInfo.EnvironmentVariables since that would not allow us
to re-use the instance when changing UseShellExecute. Added argument check in
Start (ProcessStartInfo). Code formatting.
* ProcessTest.cs: Added tests for Start overloads.

svn path=/trunk/mcs/; revision=90693
2007-12-04 16:37:36 +00:00
Jb Evain 69c630429f 2007-11-16 Jb Evain <[email protected]>
* Debug_2_1.cs: simply write debug messages to the
	console.


svn path=/trunk/mcs/; revision=89763
2007-11-16 15:13:21 +00:00