summaryrefslogtreecommitdiff
path: root/platform/macos/joypad_macos.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/macos/joypad_macos.cpp')
-rw-r--r--platform/macos/joypad_macos.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/macos/joypad_macos.cpp b/platform/macos/joypad_macos.cpp
index b7b8e0604c..1fcd636a4b 100644
--- a/platform/macos/joypad_macos.cpp
+++ b/platform/macos/joypad_macos.cpp
@@ -316,7 +316,7 @@ bool JoypadMacOS::configure_joypad(IOHIDDeviceRef p_device_ref, joypad *p_joy) {
if (vendor && product_id) {
char uid[128];
- sprintf(uid, "%08x%08x%08x%08x", OSSwapHostToBigInt32(3), OSSwapHostToBigInt32(vendor), OSSwapHostToBigInt32(product_id), OSSwapHostToBigInt32(version));
+ snprintf(uid, 128, "%08x%08x%08x%08x", OSSwapHostToBigInt32(3), OSSwapHostToBigInt32(vendor), OSSwapHostToBigInt32(product_id), OSSwapHostToBigInt32(version));
input->joy_connection_changed(id, true, name, uid);
} else {
// Bluetooth device.