Initial original import from: fuse-2.4.2-2.fc4
[captive.git] / src / libcaptive / io / process.c
index 7e3c96b..e909442 100644 (file)
@@ -21,6 +21,7 @@
 
 #include "reactos/ddk/iofuncs.h"       /* self */
 #include <glib/gmessages.h>
+#include "reactos/ddk/psfuncs.h"       /* for PsGetCurrentThread() */
 
 
 /**
@@ -40,3 +41,22 @@ VOID IoGetStackLimits(OUT PULONG LowLimit,OUT PULONG HighLimit)
        *LowLimit =(ULONG) 0x10000;     /* 64KB */
        *HighLimit=(ULONG)-0x10000;     /* 64KB */
 }
+
+
+/**
+ * IoIsSystemThread:
+ * @Thread: #PETHREAD of the thread to query.
+ * libcaptive allows only PsGetCurrentThread() value.
+ *
+ * Detect if the given @Thread is a kernel system thread.
+ * FIXME: Not much specific...
+ *
+ * Returns: %TRUE if the given @Thread is a kernel system thread.
+ * libcaptive always returns %TRUE.
+ */
+BOOLEAN IoIsSystemThread(IN PETHREAD Thread)
+{
+       g_return_val_if_fail(Thread==PsGetCurrentThread(),FALSE);
+
+       return TRUE;
+}