comparison src/mbyte.c @ 26865:bce848ec8b1b v8.2.3961

patch 8.2.3961: error messages are spread out Commit: https://github.com/vim/vim/commit/436b5adc9770a2568209dd5ab1f98bd1afc91898 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Dec 31 22:49:24 2021 +0000 patch 8.2.3961: error messages are spread out Problem: Error messages are spread out. Solution: Move more errors to errors.h.
author Bram Moolenaar <Bram@vim.org>
date Sat, 01 Jan 2022 00:00:04 +0100
parents 9f445e07f766
children 06a137af96f8
comparison
equal deleted inserted replaced
26864:eb95ad159bce 26865:bce848ec8b1b
528 { 528 {
529 #ifdef MSWIN 529 #ifdef MSWIN
530 // Windows: accept only valid codepage numbers, check below. 530 // Windows: accept only valid codepage numbers, check below.
531 if (p_enc[6] != 'c' || p_enc[7] != 'p' 531 if (p_enc[6] != 'c' || p_enc[7] != 'p'
532 || (enc_dbcs_new = atoi((char *)p_enc + 8)) == 0) 532 || (enc_dbcs_new = atoi((char *)p_enc + 8)) == 0)
533 return e_invarg; 533 return e_invalid_argument;
534 #else 534 #else
535 // Unix: accept any "2byte-" name, assume current locale. 535 // Unix: accept any "2byte-" name, assume current locale.
536 enc_dbcs_new = DBCS_2BYTE; 536 enc_dbcs_new = DBCS_2BYTE;
537 #endif 537 #endif
538 } 538 }
561 enc_unicode = 0; 561 enc_unicode = 0;
562 enc_utf8 = FALSE; 562 enc_utf8 = FALSE;
563 } 563 }
564 } 564 }
565 else // Don't know what encoding this is, reject it. 565 else // Don't know what encoding this is, reject it.
566 return e_invarg; 566 return e_invalid_argument;
567 567
568 if (enc_dbcs_new != 0) 568 if (enc_dbcs_new != 0)
569 { 569 {
570 #ifdef MSWIN 570 #ifdef MSWIN
571 // Check if the DBCS code page is OK. 571 // Check if the DBCS code page is OK.