Software for the Open Enterprise™

Wiki Toolbox

View of /FreeBSD-ports/deskutils/beagle/files/patch-Util_FileAdvise.cs

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (download) (annotate)
Sat Mar 17 04:40:02 2007 UTC (2 years, 8 months ago) by tmclau02
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +5 -5 lines
Update to 0.2.16.3
- add patch to work around posix_fadvise [1]

Submitted by:	Must Karu (via OpenSolaris) [1]
--- Util/FileAdvise.cs.orig	Thu Mar 15 18:31:16 2007
+++ Util/FileAdvise.cs	Thu Mar 15 18:35:14 2007
@@ -39,8 +39,6 @@
 
 		// FIXME: On 64-bit architectures, we need to use "long" not "int" here for
 		// "offset" and "len"
-		[DllImport ("libc", SetLastError=true)]
-		static extern int posix_fadvise (int fd, int offset, int len, int advice);
 
 		// The following are from /usr/include/linux/fadvise.h and will not change
 		private const int AdviseNormal = 0;	// POSIX_FADV_NORMAL
@@ -52,8 +50,7 @@
 
 		static private int GiveAdvice (FileStream file, int advice)
 		{
-			int fd = file.Handle.ToInt32 ();
-			return posix_fadvise (fd, 0, 0, advice);
+			return 0;
 		}
 
 		static public void FlushCache (FileStream file)

Corporate Governance | Legal | Privacy | Subscribe | Feedback | Glossary | RSS | Contact

© 2006 Novell, Inc. All Rights Reserved.