]> git.wh0rd.org Git - nano.git/commitdiff
Renaming a variable and reshuffling a few lines.
authorBenno Schulenberg <bensberg@justemail.net>
Mon, 29 Feb 2016 12:17:53 +0000 (12:17 +0000)
committerBenno Schulenberg <bensberg@justemail.net>
Mon, 29 Feb 2016 12:17:53 +0000 (12:17 +0000)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5701 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

ChangeLog
src/rcfile.c

index aa916a90474dac0aaa468ab130ebf11a79f1c757..5321265b98fabae732bc6a24f8966a61ef17ac99 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,7 @@
        syntax, and thus prevent it from being extended.
        * src/nano.h, src/rcfile.c: Arrange some things more orderly.
        * src/rcfile.c (parse_rcfile): Close an extended syntax again.
+       * src/rcfile.c (parse_rcfile): Rename a variable.
 
 2016-02-28  Benno Schulenberg  <bensberg@justemail.net>
        * src/rcfile.c (parse_header_exp): Don't continue when something is
index 1b7fe7e06eac1322bf55f890cf764a39fd02e8d0..76a8b277f76aa1fb78042121db1e77eea8e79fa6 100644 (file)
@@ -1053,22 +1053,24 @@ void parse_rcfile(FILE *rcstream
 #ifndef DISABLE_COLOR
        /* Handle extending first... */
        if (strcasecmp(keyword, "extendsyntax") == 0) {
+           syntaxtype *sint;
            char *syntaxname = ptr;
-           syntaxtype *ts = NULL;
 
            ptr = parse_next_word(ptr);
-           for (ts = syntaxes; ts != NULL; ts = ts->next)
-               if (!strcmp(ts->name, syntaxname))
+
+           for (sint = syntaxes; sint != NULL; sint = sint->next)
+               if (!strcmp(sint->name, syntaxname))
                    break;
 
-           if (ts == NULL) {
-               rcfile_error(N_("Could not find syntax \"%s\" to extend"), syntaxname);
+           if (sint == NULL) {
+               rcfile_error(N_("Could not find syntax \"%s\" to extend"),
+                               syntaxname);
                opensyntax = FALSE;
                continue;
            } else {
-               opensyntax = TRUE;
                end_syn_save = endsyntax;
-               endsyntax = ts;
+               endsyntax = sint;
+               opensyntax = TRUE;
                keyword = ptr;
                ptr = parse_next_word(ptr);
            }