aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar Simon Marlow <simonmar@microsoft.com>2007-02-26 11:03:11 +0000
committerGravatar Simon Marlow <simonmar@microsoft.com>2007-02-26 11:03:11 +0000
commitb76084ef81d1d48782920dbd81fbdf30db5a4e3a (patch)
treed0a411913b2bdd17cb642c132d95e8cc30bc2e6f /include
parent74d4e5440730ccb0c8fc90c276fe8c5d26f9248d (diff)
add C wrappers for lstat() and mknod(). Fixes #1086.
Diffstat (limited to 'include')
-rw-r--r--include/HsUnix.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/HsUnix.h b/include/HsUnix.h
index 8669b30..9b2e697 100644
--- a/include/HsUnix.h
+++ b/include/HsUnix.h
@@ -118,4 +118,16 @@ INLINE int __hsunix_SIGINFO() { return SIGINFO; }
INLINE int __hsunix_SIGWINCH() { return SIGWINCH; }
#endif
+// lstat is a macro on some platforms, so we need a wrapper:
+INLINE int __hsunix_lstat(const char *path, struct stat *buf)
+{
+ return lstat(path,buf);
+}
+
+// lstat is a macro on some platforms, so we need a wrapper:
+INLINE int __hsunix_mknod(const char *pathname, mode_t mode, dev_t dev)
+{
+ return mknod(pathname,mode,dev);
+}
+
#endif