Fixes warning that strncpy is not able to append NULL to the end
of destination.

Signed-off-by: Pauli Nieminen <ext-pauli.niemi...@nokia.com>
---
 xkb/xkmread.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/xkb/xkmread.c b/xkb/xkmread.c
index 814bb1d..9eb8601 100644
--- a/xkb/xkmread.c
+++ b/xkb/xkmread.c
@@ -534,8 +534,7 @@ XkbAction               *act;
 
         case XkbSA_XFree86Private:
             /* copy the kind of action */
-            strncpy((char*)act->any.data, (char*)wire.actionData,
-                    XkbAnyActionDataSize);
+            memcpy(act->any.data, wire.actionData, XkbAnyActionDataSize);
             break ;
 
         case XkbSA_Terminate:
-- 
1.6.3.3

_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to