summaryrefslogtreecommitdiffstats
path: root/waltham-transmitter/transmitter-plugin/output.c
diff options
context:
space:
mode:
authorNaoko Tanibata <tnaoko@jp.adit-jv.com>2018-11-19 11:32:10 +0900
committerNaoko Tanibata <tnaoko@jp.adit-jv.com>2018-11-19 11:32:10 +0900
commit8d837e2f33b6b2989c037c9552dd99446164a20f (patch)
tree749c1540fac254790fe2e281884e0e9f5053752a /waltham-transmitter/transmitter-plugin/output.c
parenta1974a6a8cf8ed073b08bc65b01a6a6e99251723 (diff)
transmitter: Fix the return value of transmitter_output_enable
Change-Id: I630c26ecbc506052baf1c9ea3ab3f07be1ff393a Signed-off-by: Naoko Tanibata <tnaoko@jp.adit-jv.com>
Diffstat (limited to 'waltham-transmitter/transmitter-plugin/output.c')
-rw-r--r--waltham-transmitter/transmitter-plugin/output.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/waltham-transmitter/transmitter-plugin/output.c b/waltham-transmitter/transmitter-plugin/output.c
index c379ce5..b98e170 100644
--- a/waltham-transmitter/transmitter-plugin/output.c
+++ b/waltham-transmitter/transmitter-plugin/output.c
@@ -255,15 +255,20 @@ transmitter_assign_planes(struct weston_output *base) {
}
}
-static void
+static int
transmitter_output_enable(struct weston_output *base)
{
struct weston_transmitter_output *output = wl_container_of(base, output, base);
-
+ if (!output) {
+ weston_log("No weston output found\n");
+ return -1;
+ }
output->base.assign_planes = transmitter_assign_planes;
output->base.set_backlight = NULL;
output->base.set_dpms = NULL;
output->base.switch_mode = NULL;
+
+ return 0;
}
int