summaryrefslogtreecommitdiffstats
path: root/swaylock
diff options
context:
space:
mode:
authorLibravatar Björn Esser <besser82@fedoraproject.org>2017-12-14 17:14:47 +0100
committerLibravatar Björn Esser <besser82@fedoraproject.org>2017-12-14 18:47:24 +0100
commit02da9c4e7cafb36083566e511cc7913d8922aaa6 (patch)
treec7993993d3f0536512a0ddfb811f44d7cc7479fe /swaylock
parentipc-server: Acquire ownership of referenced json_object properly (diff)
downloadsway-02da9c4e7cafb36083566e511cc7913d8922aaa6.tar.gz
sway-02da9c4e7cafb36083566e511cc7913d8922aaa6.tar.zst
sway-02da9c4e7cafb36083566e511cc7913d8922aaa6.zip
Adaptions for API change in json-c v0.13
Diffstat (limited to 'swaylock')
-rw-r--r--swaylock/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/swaylock/main.c b/swaylock/main.c
index c2615951..7b7dd601 100644
--- a/swaylock/main.c
+++ b/swaylock/main.c
@@ -3,7 +3,6 @@
3#include <xkbcommon/xkbcommon.h> 3#include <xkbcommon/xkbcommon.h>
4#include <xkbcommon/xkbcommon-names.h> 4#include <xkbcommon/xkbcommon-names.h>
5#include <security/pam_appl.h> 5#include <security/pam_appl.h>
6#include <json-c/json.h>
7#include <stdio.h> 6#include <stdio.h>
8#include <stdlib.h> 7#include <stdlib.h>
9#include <string.h> 8#include <string.h>
@@ -13,6 +12,7 @@
13#include <signal.h> 12#include <signal.h>
14#include <stdbool.h> 13#include <stdbool.h>
15#include <unistd.h> 14#include <unistd.h>
15#include "sway_json_helper.h"
16#include "client/window.h" 16#include "client/window.h"
17#include "client/registry.h" 17#include "client/registry.h"
18#include "client/cairo.h" 18#include "client/cairo.h"
@@ -584,7 +584,7 @@ int main(int argc, char **argv) {
584 584
585 for (i = 0; i < registry->outputs->length; ++i) { 585 for (i = 0; i < registry->outputs->length; ++i) {
586 if (displays_paths[i * 2] != NULL) { 586 if (displays_paths[i * 2] != NULL) {
587 for (int j = 0;; ++j) { 587 for (json_ar_len_t j = 0;; ++j) {
588 if (j >= json_object_array_length(json_outputs)) { 588 if (j >= json_object_array_length(json_outputs)) {
589 sway_log(L_ERROR, "%s is not an extant output", displays_paths[i * 2]); 589 sway_log(L_ERROR, "%s is not an extant output", displays_paths[i * 2]);
590 exit(EXIT_FAILURE); 590 exit(EXIT_FAILURE);