aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Engestrom <eric.engestrom@intel.com>2019-07-08 16:14:28 (GMT)
committerEric Engestrom <eric.engestrom@intel.com>2019-07-21 09:38:17 (GMT)
commitf7224014df0d366453739356b9968ca94ad43979 (patch)
tree6ce2be7ae753fd8ef8dae71e2e201df23b07ae1a
parent29e8f15bdc69449a1116817ef3febefeab9eb53b (diff)
downloadexternal_mesa3d-f7224014df0d366453739356b9968ca94ad43979.zip
external_mesa3d-f7224014df0d366453739356b9968ca94ad43979.tar.gz
external_mesa3d-f7224014df0d366453739356b9968ca94ad43979.tar.bz2
radv: replace memset()+strcpy() with snprintf()
Just like the next line :) Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
-rw-r--r--src/amd/vulkan/radv_device.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c
index af7fcb6..a4ec2e4 100644
--- a/src/amd/vulkan/radv_device.c
+++ b/src/amd/vulkan/radv_device.c
@@ -1340,9 +1340,7 @@ void radv_GetPhysicalDeviceProperties2(
(VkPhysicalDeviceDriverPropertiesKHR *) ext;
driver_props->driverID = VK_DRIVER_ID_MESA_RADV_KHR;
- memset(driver_props->driverName, 0, VK_MAX_DRIVER_NAME_SIZE_KHR);
- strcpy(driver_props->driverName, "radv");
-
+ snprintf(driver_props->driverName, VK_MAX_DRIVER_NAME_SIZE_KHR, "radv");
snprintf(driver_props->driverInfo, VK_MAX_DRIVER_INFO_SIZE_KHR,
"Mesa " PACKAGE_VERSION MESA_GIT_SHA1
" (LLVM " MESA_LLVM_VERSION_STRING ")");