Mercurial > vim
comparison src/buffer.c @ 15490:98c35d312987 v8.1.0753
patch 8.1.0753: printf format not checked for semsg()
commit https://github.com/vim/vim/commit/b5443cc46dd1485d6c785dd8c65a2c07bd5a17f3
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Jan 15 20:19:40 2019 +0100
patch 8.1.0753: printf format not checked for semsg()
Problem: printf format not checked for semsg().
Solution: Add GNUC attribute and fix reported problems. (Dominique Pelle,
closes #3805)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 15 Jan 2019 20:30:07 +0100 |
parents | 55ccc2d353bd |
children | 41fbbcea0f1b |
comparison
equal
deleted
inserted
replaced
15489:3bbefd5c9d0d | 15490:98c35d312987 |
---|---|
1405 return FAIL; | 1405 return FAIL; |
1406 } | 1406 } |
1407 else | 1407 else |
1408 #endif | 1408 #endif |
1409 { | 1409 { |
1410 semsg(_("E89: No write since last change for buffer %ld (add ! to override)"), | 1410 semsg(_("E89: No write since last change for buffer %d (add ! to override)"), |
1411 buf->b_fnum); | 1411 buf->b_fnum); |
1412 return FAIL; | 1412 return FAIL; |
1413 } | 1413 } |
1414 } | 1414 } |
1415 | 1415 |
2281 if (buf == NULL) | 2281 if (buf == NULL) |
2282 { | 2282 { |
2283 if ((options & GETF_ALT) && n == 0) | 2283 if ((options & GETF_ALT) && n == 0) |
2284 emsg(_(e_noalt)); | 2284 emsg(_(e_noalt)); |
2285 else | 2285 else |
2286 semsg(_("E92: Buffer %ld not found"), n); | 2286 semsg(_("E92: Buffer %d not found"), n); |
2287 return FAIL; | 2287 return FAIL; |
2288 } | 2288 } |
2289 | 2289 |
2290 /* if alternate file is the current buffer, nothing to do */ | 2290 /* if alternate file is the current buffer, nothing to do */ |
2291 if (buf == curbuf) | 2291 if (buf == curbuf) |