chiark / gitweb /
terminal: sysview: don't return uninitialized error codes
authorDavid Herrmann <dh.herrmann@gmail.com>
Thu, 28 Aug 2014 09:01:31 +0000 (11:01 +0200)
committerDavid Herrmann <dh.herrmann@gmail.com>
Thu, 28 Aug 2014 09:04:18 +0000 (11:04 +0200)
commit371ad55d460559b4262e25d0f9b64dc37c3f7565
treea8a24b7c6356539fe9b25048d5ab7c35b18d71b3
parent0f99f74a14ef193c1ebde687c5cc76e1d67b85ef
terminal: sysview: don't return uninitialized error codes

In case 'scan_evdev' and 'scan_drm' are both false, we never set 'r' to
anyhting, thus return an uninitialized error code. Fix this by always
returning 0 as we catch negative codes earlier, anyway. Thanks to Thomas
H.P. Anderson for the report.
src/libsystemd-terminal/sysview.c