Skip to content

Commit

Permalink
Fix clang warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mikkeloscar committed Feb 8, 2016
1 parent 4546ce1 commit bacd40d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion common/log.c
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ void error_handler(int sig) {
sway_log(L_ERROR, "Unable to allocate memory to show maps");
break;
}
sway_log(L_ERROR, m);
sway_log(L_ERROR, "%s", m);
}
fclose(maps);
}
Expand Down
4 changes: 2 additions & 2 deletions sway/commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -870,8 +870,8 @@ static struct cmd_results *cmd_move(int argc, char **argv) {
uint32_t w = size->w - g.size.w;
uint32_t h = size->h - g.size.h;

view->x = g.origin.x = MIN(w, MAX(x, 0));
view->y = g.origin.y = MIN(h, MAX(y, 0));
view->x = g.origin.x = MIN((int32_t)w, MAX(x, 0));
view->y = g.origin.y = MIN((int32_t)h, MAX(y, 0));

wlc_view_set_geometry(view->handle, 0, &g);
}
Expand Down

0 comments on commit bacd40d

Please sign in to comment.