mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-01 12:46:12 +00:00
st/oxr: Silence warning from snprintf when compiling with optimisations
This commit is contained in:
parent
d6465bc017
commit
e8ead02c4c
|
@ -179,11 +179,9 @@ oxr_system_get_properties(struct oxr_logger *log,
|
||||||
properties->vendorId = 42;
|
properties->vendorId = 42;
|
||||||
properties->systemId = sys->systemId;
|
properties->systemId = sys->systemId;
|
||||||
|
|
||||||
// Needed to silence the warnings.
|
// The magical 247 number, is to silence warnings.
|
||||||
const char *name = sys->head->str;
|
snprintf(properties->systemName, XR_MAX_SYSTEM_NAME_SIZE,
|
||||||
|
"Monado: %.*s", 247, sys->head->str);
|
||||||
snprintf(properties->systemName, XR_MAX_SYSTEM_NAME_SIZE, "Monado: %s",
|
|
||||||
name);
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* @todo conforming implementations must support at
|
* @todo conforming implementations must support at
|
||||||
|
|
Loading…
Reference in a new issue