projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
29e8f15
)
radv: replace memset()+strcpy() with snprintf()
author
Eric Engestrom
<eric.engestrom@intel.com>
Mon, 8 Jul 2019 16:14:28 +0000
(17:14 +0100)
committer
Eric Engestrom
<eric.engestrom@intel.com>
Sun, 21 Jul 2019 09:38:17 +0000
(10:38 +0100)
Just like the next line :)
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
src/amd/vulkan/radv_device.c
patch
|
blob
|
history
diff --git
a/src/amd/vulkan/radv_device.c
b/src/amd/vulkan/radv_device.c
index af7fcb6fcff200af4e6212a124dc0ed512d6efbb..a4ec2e4ac1604c4297d6c8b6b47e10b5a20cca57 100644
(file)
--- 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 ")");