From: Volker Lendecke Date: Sun, 28 Apr 2024 14:07:44 +0000 (+0200) Subject: libsmb: Slightly simplify py_cli_list() X-Git-Tag: tdb-1.4.11~889 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ceea95af632cc1a7bec6c32c7b0daa54bf3d26c0;p=thirdparty%2Fsamba.git libsmb: Slightly simplify py_cli_list() We don't need an & to take a function pointer Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/source3/libsmb/pylibsmb.c b/source3/libsmb/pylibsmb.c index aa87fa0c1a2..e24f78ee9df 100644 --- a/source3/libsmb/pylibsmb.c +++ b/source3/libsmb/pylibsmb.c @@ -2077,7 +2077,7 @@ static PyObject *py_cli_list(struct py_cli_state *self, const char *kwlist[] = { "directory", "mask", "attribs", "info_level", NULL }; NTSTATUS (*callback_fn)(struct file_info *, const char *, void *) = - &list_helper; + list_helper; if (!ParseTupleAndKeywords(args, kwds, "z|sII:list", kwlist, &base_dir, &user_mask, &attribute, @@ -2099,7 +2099,7 @@ static PyObject *py_cli_list(struct py_cli_state *self, } if (info_level == SMB2_FIND_POSIX_INFORMATION) { - callback_fn = &list_posix_helper; + callback_fn = list_posix_helper; } status = do_listing(self, base_dir, user_mask, attribute, info_level, callback_fn, result);