[Bsd-sharp-cvs] CVS commit to /cvsroot/bsd-sharp/FreeBSD-ports/audio/last-exit/files by killfill

noreply at forge.novell.com noreply at forge.novell.com
Mon Mar 26 17:42:47 MDT 2007


CVS commit to /cvsroot/bsd-sharp/FreeBSD-ports/audio/last-exit/files by killfill

Modified Files:
	patch-src-Driver.cs 
Log Message:
Handle SetProcessName

===================================================================
RCS file: /cvsroot/bsd-sharp/FreeBSD-ports/audio/last-exit/files/patch-src-Driver.cs,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- /cvsroot/bsd-sharp/FreeBSD-ports/audio/last-exit/files/patch-src-Driver.cs	2006/10/11 03:56:56	1.1
+++ /cvsroot/bsd-sharp/FreeBSD-ports/audio/last-exit/files/patch-src-Driver.cs	2007/03/26 23:42:47	1.2
@@ -1,14 +1,22 @@
---- src/Driver.cs.orig	Tue Oct 10 22:19:44 2006
-+++ src/Driver.cs	Tue Oct 10 22:20:00 2006
-@@ -173,9 +173,10 @@
- 	
+--- src/Driver.cs.orig	Mon Jan  8 21:19:05 2007
++++ src/Driver.cs	Mon Mar 26 19:34:51 2007
+@@ -200,17 +200,11 @@
+ 		}
+ 
+ 		[DllImport ("libc")]
+-			private static extern int prctl (int option,  
+-					byte[] arg2,
+-					ulong arg3,
+-					ulong arg4,
+-					ulong arg5);
++		private static extern void setproctitle(byte [] fmt, byte [] str_arg);
+ 
  		private static void SetProcessName (string name)
  		{
 -			if (prctl (15, Encoding.ASCII.GetBytes (name + "\0"), 0, 0, 0) != 0) {
-+			/*if (prctl (15, Encoding.ASCII.GetBytes (name + "\0"), 0, 0, 0) != 0) {
- 				throw new ApplicationException ("Error setting process name: " + Mono.Unix.Native.Stdlib.GetLastError ());
- 			}
-+			*/
+-				throw new ApplicationException ("Error setting process name: " + Mono.Unix.Native.Stdlib.GetLastError ());
+-			}
++			setproctitle(Encoding.ASCII.GetBytes("%s\0"), Encoding.ASCII.GetBytes(name + "\0"));
  		}
  
  		private static void SetUpConfigDirectory ()


More information about the Bsd-sharp-cvs mailing list