compositor: Fix some warning when passing debugoptimized to meson
authorMarius Vlad <marius.vlad@collabora.com>
Wed, 13 Nov 2019 09:40:26 +0000 (11:40 +0200)
committerMarius Vlad <marius.vlad@collabora.com>
Thu, 14 Nov 2019 08:54:40 +0000 (10:54 +0200)
commit9c4b5c493161780b301877de6f96316ecf9b4e93
treee62a58e9b454a6a1903b50515c99638baf2d4764
parent58e99de1a842a0801b8b3f6a024bc64d00fd5ef7
compositor: Fix some warning when passing debugoptimized to meson

Increase the buf size such it can accomodate sufficiently large local
buffers. Spotted whilst looking for something else.

../compositor/main.c:157:22: warning: ‘%s’ directive output may be
truncated writing up to 511 bytes into a region of size 128
[-Wformat-truncation=]
  157 |  snprintf(buf, len, "%s[%s.%03li]", datestr,
      |                      ^~             ~~~~~~~
../compositor/main.c:157:21: note: directive argument in the range
[-92233720368547759223372036854775]
  157 |  snprintf(buf, len, "%s[%s.%03li]", datestr,
      |                     ^~~~~~~~~~~~~~
../compositor/main.c:157:2: note: ‘snprintf’ output between 7 and 659
bytes into a destination of size 128
  157 |  snprintf(buf, len, "%s[%s.%03li]", datestr,
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  158 |    timestr, (tv.tv_usec / 1000));
      |    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
compositor/main.c