From f32b7c944b59432cbb3be2e25955cd9103803fff Mon Sep 17 00:00:00 2001 From: Piotr Sikora Date: Fri, 16 Mar 2012 04:02:06 +0000 Subject: Use strncpy() instead of strcpy(). Signed-off-by: Piotr Sikora --- src/ipc_address.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ipc_address.cpp b/src/ipc_address.cpp index dc58e6c..faea5db 100644 --- a/src/ipc_address.cpp +++ b/src/ipc_address.cpp @@ -43,7 +43,7 @@ int xs::ipc_address_t::resolve (const char *path_) } address.sun_family = AF_UNIX; - strcpy (address.sun_path, path_); + strncpy (address.sun_path, path_, sizeof (address.sun_path)); return 0; } -- cgit v1.2.3