compositor-fbdev: make copy of the device string
authorPekka Paalanen <pekka.paalanen@collabora.co.uk>
Thu, 28 Apr 2016 12:12:25 +0000 (15:12 +0300)
committerPekka Paalanen <pekka.paalanen@collabora.co.uk>
Fri, 29 Apr 2016 11:14:47 +0000 (14:14 +0300)
commite5b5659240e1c1c23bf74c0b126de982747dffa7
tree9546a5ad89b4f59aa24ed1d28daf9773aa0ac926
parentc06389a105995622841b640c56b252286ac1143c
compositor-fbdev: make copy of the device string

Ensuring that the pointer to the device path stays valid gets harder and
harder with migrating to the libweston-style config handling. Therefore,
make a copy of the string, private to struct fbdev_output.

Now the pointer passed in to fbdev_output_create() could be freed right
after the call returns.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Quentin Glidic <sardemff7+git@sardemff7.net>
Reviewed-by: Benoit Gschwind <gschwind@gnu-log.net>
src/compositor-fbdev.c