summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-04-17 10:09:02 +0200
committerStephan Bergmann <sbergman@redhat.com>2013-04-17 11:51:11 +0200
commitbe9e5c5ade8c17f73ee96ee4013e9be7b4397855 (patch)
tree567646020a19d6b8413390203e17ae2d77e8c9d4 /extensions
parente59f0a2df15e45c0d7867fa82202e4c57c39833d (diff)
-Werror=unused-variable (MinGW, extensions)
Change-Id: I88113be8ff3f4dfe641463267754ee8129bc767a
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/nsplugin/source/npshell.cxx9
-rw-r--r--extensions/source/nsplugin/source/nsp_func.hxx3
2 files changed, 9 insertions, 3 deletions
diff --git a/extensions/source/nsplugin/source/npshell.cxx b/extensions/source/nsplugin/source/npshell.cxx
index 783954515e8b..fe467b57c556 100644
--- a/extensions/source/nsplugin/source/npshell.cxx
+++ b/extensions/source/nsplugin/source/npshell.cxx
@@ -91,6 +91,15 @@
#define NP_DLLPUBLIC SAL_DLLPUBLIC_EXPORT
#endif
+#if defined WNT
+static SECURITY_ATTRIBUTES NSP_pipe_access = {
+ sizeof (SECURITY_ATTRIBUTES), NULL, TRUE };
+#define NSP_Inherited_Pipe(fd) \
+ (!CreatePipe(&fd[0], &fd[1], &NSP_pipe_access, 1024 * 10))
+#else
+#define NSP_Inherited_Pipe(fp) pipe(fd)
+#endif
+
/***********************************************************************
*
* Implementations of plugin API functions
diff --git a/extensions/source/nsplugin/source/nsp_func.hxx b/extensions/source/nsplugin/source/nsp_func.hxx
index 1e99bbbc067a..ca1a62a8ecca 100644
--- a/extensions/source/nsplugin/source/nsp_func.hxx
+++ b/extensions/source/nsplugin/source/nsp_func.hxx
@@ -43,7 +43,6 @@
//for pipe()
typedef int NSP_PIPE_FD;
-#define NSP_Inherited_Pipe(fp) pipe(fd)
#define NSP_Close_Pipe(fp) close(fp)
//for write(), read()
#define NSP_Write_Pipe(a, b, c, d) write(a, b, c)
@@ -76,8 +75,6 @@ typedef int NSP_PIPE_FD;
//for pipe()
typedef HANDLE NSP_PIPE_FD;
-static SECURITY_ATTRIBUTES NSP_pipe_access = { sizeof(SECURITY_ATTRIBUTES), NULL, TRUE};
-#define NSP_Inherited_Pipe(fd) (!CreatePipe(&fd[0], &fd[1], &NSP_pipe_access, 1024*10))
#define NSP_Close_Pipe(fp) CloseHandle(fp)
//for write(), read()
#define NSP_Write_Pipe(a, b, c, d) WriteFile(a, b, c, d, NULL)