Re: [PATCH xserver 2/8] dmx: Fix some snprintf warnings.

2018-04-06 Thread Emil Velikov
On 6 April 2018 at 09:44, Peter Hutterer wrote: > On Thu, Apr 05, 2018 at 01:13:55PM -0400, Adam Jackson wrote: >> snprintf doesn't terminate the string if it truncates, so things like >> this are lurking crashers: > > it doesn't? which platforms is that on? Apparently windows, from a quick > goog

Re: [PATCH xserver 2/8] dmx: Fix some snprintf warnings.

2018-04-06 Thread Peter Hutterer
On Thu, Apr 05, 2018 at 01:13:55PM -0400, Adam Jackson wrote: > snprintf doesn't terminate the string if it truncates, so things like > this are lurking crashers: it doesn't? which platforms is that on? Apparently windows, from a quick google but that's about it, right? Cheers, Peter > > ..

[PATCH xserver 2/8] dmx: Fix some snprintf warnings.

2018-04-05 Thread Adam Jackson
snprintf doesn't terminate the string if it truncates, so things like this are lurking crashers: ../hw/dmx/dmxprop.c: In function ‘dmxPropertyIdentifier.part.0’: ../hw/dmx/dmxprop.c:94:36: warning: ‘%s’ directive output may be truncated writing up to 255 bytes into a region of size 123 [-Wformat-