diff options
author | Yegappan Lakshmanan <yegappan@yahoo.com> | 2023-01-08 13:44:24 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2023-01-08 13:44:24 +0000 |
commit | 7f8b2559a30e2e2a443c35b28e94c6b45ba7ae04 (patch) | |
tree | 04c0145c1e3cf9777d58c91fa7b2ad231cfecf8d /src/findfile.c | |
parent | df8f9473596c8fb18ec893de677dba455e8925b3 (diff) | |
download | vim-git-7f8b2559a30e2e2a443c35b28e94c6b45ba7ae04.tar.gz |
patch 9.0.1158: code is indented more than necessaryv9.0.1158
Problem: Code is indented more than necessary.
Solution: Use an early return where it makes sense. (Yegappan Lakshmanan,
closes #11787)
Diffstat (limited to 'src/findfile.c')
-rw-r--r-- | src/findfile.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/findfile.c b/src/findfile.c index 9ce733cfd..017e1c662 100644 --- a/src/findfile.c +++ b/src/findfile.c @@ -1426,11 +1426,11 @@ ff_push(ff_search_ctx_T *search_ctx, ff_stack_T *stack_ptr) { // check for NULL pointer, not to return an error to the user, but // to prevent a crash - if (stack_ptr != NULL) - { - stack_ptr->ffs_prev = search_ctx->ffsc_stack_ptr; - search_ctx->ffsc_stack_ptr = stack_ptr; - } + if (stack_ptr == NULL) + return; + + stack_ptr->ffs_prev = search_ctx->ffsc_stack_ptr; + search_ctx->ffsc_stack_ptr = stack_ptr; } /* |