From 0830485d1cddd8567e420e80b60edcf80d26ab24 Mon Sep 17 00:00:00 2001 From: Noel Power Date: Thu, 2 May 2019 19:34:06 +0100 Subject: [PATCH] s3/ntvfs: squash 'cast between incompatible function types' warning Fix various PyCFunction definitions to avoid 'cast between incompatible function types' warnings when compiled with -Wcast-function-type Signed-off-by: Noel Power Reviewed-by: Andreas Schneider --- source4/ntvfs/posix/python/pyposix_eadb.c | 3 ++- source4/ntvfs/posix/python/pyxattr_native.c | 3 ++- source4/ntvfs/posix/python/pyxattr_tdb.c | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/source4/ntvfs/posix/python/pyposix_eadb.c b/source4/ntvfs/posix/python/pyposix_eadb.c index 646498225b3..ef4db0e867a 100644 --- a/source4/ntvfs/posix/python/pyposix_eadb.c +++ b/source4/ntvfs/posix/python/pyposix_eadb.c @@ -29,7 +29,8 @@ #include "libcli/util/pyerrors.h" #include "param/pyparam.h" -static PyObject *py_is_xattr_supported(PyObject *self) +static PyObject *py_is_xattr_supported(PyObject *self, + PyObject *Py_UNUSED(ignored)) { return Py_True; } diff --git a/source4/ntvfs/posix/python/pyxattr_native.c b/source4/ntvfs/posix/python/pyxattr_native.c index b1fa2a208e5..7d5bee0c37c 100644 --- a/source4/ntvfs/posix/python/pyxattr_native.c +++ b/source4/ntvfs/posix/python/pyxattr_native.c @@ -25,7 +25,8 @@ #include "system/filesys.h" #include "lib/util/base64.h" -static PyObject *py_is_xattr_supported(PyObject *self) +static PyObject *py_is_xattr_supported(PyObject *self, + PyObject *Py_UNUSED(ignored)) { #if !defined(HAVE_XATTR_SUPPORT) return Py_False; diff --git a/source4/ntvfs/posix/python/pyxattr_tdb.c b/source4/ntvfs/posix/python/pyxattr_tdb.c index f9a1fa5fd80..397cae77bc9 100644 --- a/source4/ntvfs/posix/python/pyxattr_tdb.c +++ b/source4/ntvfs/posix/python/pyxattr_tdb.c @@ -33,7 +33,8 @@ #include "lib/dbwrap/dbwrap_tdb.h" #include "source3/lib/xattr_tdb.h" -static PyObject *py_is_xattr_supported(PyObject *self) +static PyObject *py_is_xattr_supported(PyObject *self, + PyObject *Py_UNUSED(ignored)) { return Py_True; } -- 2.47.3