From 2fe08c886ae60c0affae0166ce1cdab1593bab3e Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 20 Aug 2012 13:43:41 +0200 Subject: s3: Fix memleaks in pylibsmb.c Cut&Paste errors from the read&x routine Signed-off-by: Jeremy Allison --- source3/libsmb/pylibsmb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source3/libsmb/pylibsmb.c') diff --git a/source3/libsmb/pylibsmb.c b/source3/libsmb/pylibsmb.c index be04e5b7db..d8e64b3568 100644 --- a/source3/libsmb/pylibsmb.c +++ b/source3/libsmb/pylibsmb.c @@ -577,9 +577,9 @@ static PyObject *py_cli_ftruncate(struct py_cli_state *self, PyObject *args, return NULL; } status = cli_ftruncate_recv(req); + TALLOC_FREE(req); if (!NT_STATUS_IS_OK(status)) { - TALLOC_FREE(req); PyErr_SetNTSTATUS(status); return NULL; } @@ -609,9 +609,9 @@ static PyObject *py_cli_delete_on_close(struct py_cli_state *self, return NULL; } status = cli_nt_delete_on_close_recv(req); + TALLOC_FREE(req); if (!NT_STATUS_IS_OK(status)) { - TALLOC_FREE(req); PyErr_SetNTSTATUS(status); return NULL; } -- cgit