diff options
| author | Mikael Magnusson <mikachu@gmail.com> | 2014-10-28 04:34:21 +0100 |
|---|---|---|
| committer | Mikael Magnusson <mikachu@gmail.com> | 2014-10-28 04:34:21 +0100 |
| commit | 1387b33394a219e0a64015d614fc9a44e611901b (patch) | |
| tree | f02fcc164a881ffe0b9eb2720df2a5d3822bfe60 | |
| parent | 396198081e72d6d758d51d4c6cdda1105be0df2d (diff) | |
Fix an if statement getting moved into a loop it shouldn't have
Found by coverity code analysis.
| -rw-r--r-- | openbox/place.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/openbox/place.c b/openbox/place.c index aa3ff636..de2c7dc9 100644 --- a/openbox/place.c +++ b/openbox/place.c @@ -360,11 +360,11 @@ static gboolean place_transient_splash(ObClient *client, Rect *area, b = MAX(b, RECT_BOTTOM(m->frame->area)); } } - if (!first) { - *x = ((r + 1 - l) - frame_size.width) / 2 + l; - *y = ((b + 1 - t) - frame_size.height) / 2 + t; - return TRUE; - } + } + if (!first) { + *x = ((r + 1 - l) - frame_size.width) / 2 + l; + *y = ((b + 1 - t) - frame_size.height) / 2 + t; + return TRUE; } } |
