]> git.sur5r.net Git - i3/i3/blobdiff - src/output.c
get_output_for_con: Assert result != NULL
[i3/i3] / src / output.c
index ebba5c77d40670afefe7b83f92245a5afea3b71f..3d931b1b567aa260d062ba770e3f7b92677dc794 100644 (file)
@@ -54,16 +54,8 @@ char *output_primary_name(Output *output) {
 
 Output *get_output_for_con(Con *con) {
     Con *output_con = con_get_output(con);
-    if (output_con == NULL) {
-        ELOG("Could not get the output container for con = %p.\n", con);
-        return NULL;
-    }
-
     Output *output = get_output_by_name(output_con->name, true);
-    if (output == NULL) {
-        ELOG("Could not get output from name \"%s\".\n", output_con->name);
-        return NULL;
-    }
+    assert(output != NULL);
 
     return output;
 }