From: Volker Lendecke Date: Fri, 22 Jan 2021 18:33:51 +0000 (+0100) Subject: libndr: Simplify ndr_print_GUID() X-Git-Tag: tevent-0.11.0~1888 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9374313f0333a1501d6fb823dbed86fb136f0766;p=thirdparty%2Fsamba.git libndr: Simplify ndr_print_GUID() Fix a small memleak of the tmp GUID_string Signed-off-by: Volker Lendecke Reviewed-by: Samuel Cabrero --- diff --git a/librpc/ndr/ndr_misc.c b/librpc/ndr/ndr_misc.c index 155ab8f21b8..0cbaa0b2a2f 100644 --- a/librpc/ndr/ndr_misc.c +++ b/librpc/ndr/ndr_misc.c @@ -28,7 +28,8 @@ _PUBLIC_ void ndr_print_GUID(struct ndr_print *ndr, const char *name, const struct GUID *guid) { - ndr->print(ndr, "%-25s: %s", name, GUID_string(ndr, guid)); + struct GUID_txt_buf buf; + ndr->print(ndr, "%-25s: %s", name, GUID_buf_string(guid, &buf)); } bool ndr_syntax_id_equal(const struct ndr_syntax_id *i1,