From f7f0739311927ad177dece7119272481b75b73b4 Mon Sep 17 00:00:00 2001 From: Colin Harrison Date: Tue, 19 Oct 2010 23:42:53 +0100 Subject: [PATCH] hw/xwin: Warning fix in ProcWindowsWMFrameSetTitle() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit winwindowswm.c: In function ‘ProcWindowsWMFrameSetTitle’: winwindowswm.c:514: error: pointer targets in passing argument 2 of ‘strncpy’ differ in signedness If you're going to stick random casts into your code, at least use the goddammed right ones. :-) Signed-off-by: Colin Harrison Reviewed-by: Jon TURNEY --- hw/xwin/winwindowswm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/xwin/winwindowswm.c b/hw/xwin/winwindowswm.c index 88c375733..01ae088e8 100644 --- a/hw/xwin/winwindowswm.c +++ b/hw/xwin/winwindowswm.c @@ -491,7 +491,7 @@ ProcWindowsWMFrameSetTitle(ClientPtr client) #endif title_bytes = malloc(title_length + 1); - strncpy(title_bytes, (unsigned char *) &stuff[1], title_length); + strncpy(title_bytes, (char *) &stuff[1], title_length); title_bytes[title_length] = '\0'; pRLWinPriv = (win32RootlessWindowPtr) RootlessFrameForWindow(pWin, FALSE);