From 925bd5794ece33708050a4d1af75ecb118a7d6da Mon Sep 17 00:00:00 2001 From: dgp Date: Tue, 18 Oct 2016 19:16:35 +0000 Subject: Use memcmp where possible. --- generic/tclCmdMZ.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c index 5479971..591e31c 100644 --- a/generic/tclCmdMZ.c +++ b/generic/tclCmdMZ.c @@ -1242,8 +1242,8 @@ StringFirstCmd( * Scan forward to find the first character. */ - if ((*p == *needleStr) && (TclUniCharNcmp(needleStr, p, - (unsigned long) needleLen) == 0)) { + if ((*p == *needleStr) && (memcmp(needleStr, p, + sizeof(Tcl_UniChar) * (size_t)needleLen) == 0)) { match = p - haystackStr; break; } -- cgit v0.12