Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add curly braces to if statements
  • Loading branch information
jpchip committed Oct 21, 2016
commit 42572ec47fcd8fc97216a33529413cb8f0de2148
15 changes: 9 additions & 6 deletions overviewer_core/src/primitives/overlay-bounds.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,16 +98,18 @@ static int overlay_bounds_start(void *data, RenderState *state, PyObject *suppor

/* first, chain up */
int ret = primitive_overlay.start(data, state, support);
if (ret != 0)
return ret;
if (ret != 0) {
return ret;
}

/* now do custom initializations */
self = (RenderPrimitiveBounds *)data;

// opt is a borrowed reference. do not deref
// store the bounds python object into opt.
if (!render_mode_parse_option(support, "bounds", "O", &(opt)))
return 1;
if (!render_mode_parse_option(support, "bounds", "O", &(opt))) {
return 1;
}

/**
* Check if a sane option was passed.
Expand Down Expand Up @@ -220,8 +222,9 @@ static void overlay_bounds_finish(void *data, RenderState *state) {
// freeing the nested bounds
struct Color * m = self->bounds;
for(i = 0; i < self->numcolors; i++){
if(m[i].conditions)
free(m[i].conditions);
if(m[i].conditions) {
free(m[i].conditions);
}
}
}

Expand Down