aboutsummaryrefslogtreecommitdiff
path: root/src/whirligig.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2021-07-21 13:26:37 +0200
committerThomas White <taw@physics.org>2021-07-21 15:34:33 +0200
commit7e5536832b22036a634a74e16073b4762a416e29 (patch)
tree25799eb139d235f524a80c53fb25d0c9f64eb6f1 /src/whirligig.c
parent760f17f56b7f79f67a9029cbe7cc55a0acccd3b9 (diff)
Reduce variable scope where possible
Diffstat (limited to 'src/whirligig.c')
-rw-r--r--src/whirligig.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/whirligig.c b/src/whirligig.c
index 546301ba..611825ba 100644
--- a/src/whirligig.c
+++ b/src/whirligig.c
@@ -403,8 +403,6 @@ static void connect_series(struct window *win)
{
while ( win->join_ptr < win->ws ) {
- int i;
-
if ( win->join_ptr == 0 ) {
win->join_ptr++;
continue;
@@ -415,6 +413,7 @@ static void connect_series(struct window *win)
/* Try to join this frame to each of the active series */
if ( win->join_ptr > 1 ) {
+ int i;
for ( i=0; i<MAX_SER; i++ ) {
if ( win->ser[i][win->join_ptr-1] != -1 ) {
try_join(win, i);