Mercurial > vim
diff src/spellfile.c @ 19760:9daed26b788b v8.2.0436
patch 8.2.0436: no warnings for incorrect printf arguments
Commit: https://github.com/vim/vim/commit/db99f9f29a248b84742b6779c3343123f72065e7
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Mar 23 22:12:22 2020 +0100
patch 8.2.0436: no warnings for incorrect printf arguments
Problem: No warnings for incorrect printf arguments.
Solution: Fix attribute in declaration. Fix uncovered mistakes. (Dominique
Pelle, closes #5834)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 23 Mar 2020 22:15:05 +0100 |
parents | af1eca322b9e |
children | 435726a03481 |
line wrap: on
line diff
--- a/src/spellfile.c +++ b/src/spellfile.c @@ -4115,7 +4115,7 @@ spell_read_wordfile(spellinfo_T *spin, c pc = string_convert(&spin->si_conv, rline, NULL); if (pc == NULL) { - smsg(_("Conversion failure for word in %s line %d: %s"), + smsg(_("Conversion failure for word in %s line %ld: %s"), fname, lnum, rline); continue; } @@ -4133,10 +4133,10 @@ spell_read_wordfile(spellinfo_T *spin, c if (STRNCMP(line, "encoding=", 9) == 0) { if (spin->si_conv.vc_type != CONV_NONE) - smsg(_("Duplicate /encoding= line ignored in %s line %d: %s"), + smsg(_("Duplicate /encoding= line ignored in %s line %ld: %s"), fname, lnum, line - 1); else if (did_word) - smsg(_("/encoding= line after word ignored in %s line %d: %s"), + smsg(_("/encoding= line after word ignored in %s line %ld: %s"), fname, lnum, line - 1); else { @@ -4159,13 +4159,13 @@ spell_read_wordfile(spellinfo_T *spin, c if (STRNCMP(line, "regions=", 8) == 0) { if (spin->si_region_count > 1) - smsg(_("Duplicate /regions= line ignored in %s line %d: %s"), + smsg(_("Duplicate /regions= line ignored in %s line %ld: %s"), fname, lnum, line); else { line += 8; if (STRLEN(line) > MAXREGIONS * 2) - smsg(_("Too many regions in %s line %d: %s"), + smsg(_("Too many regions in %s line %ld: %s"), fname, lnum, line); else { @@ -4179,7 +4179,7 @@ spell_read_wordfile(spellinfo_T *spin, c continue; } - smsg(_("/ line ignored in %s line %d: %s"), + smsg(_("/ line ignored in %s line %ld: %s"), fname, lnum, line - 1); continue; } @@ -4209,7 +4209,7 @@ spell_read_wordfile(spellinfo_T *spin, c l = *p - '0'; if (l == 0 || l > spin->si_region_count) { - smsg(_("Invalid region nr in %s line %d: %s"), + smsg(_("Invalid region nr in %s line %ld: %s"), fname, lnum, p); break; } @@ -4217,7 +4217,7 @@ spell_read_wordfile(spellinfo_T *spin, c } else { - smsg(_("Unrecognized flags in %s line %d: %s"), + smsg(_("Unrecognized flags in %s line %ld: %s"), fname, lnum, p); break; }