patch 8.2.3961: error messages are spread out
Problem: Error messages are spread out.
Solution: Move more errors to errors.h.
diff --git a/src/mbyte.c b/src/mbyte.c
index 0e9c926..bbbb506 100644
--- a/src/mbyte.c
+++ b/src/mbyte.c
@@ -530,7 +530,7 @@
// Windows: accept only valid codepage numbers, check below.
if (p_enc[6] != 'c' || p_enc[7] != 'p'
|| (enc_dbcs_new = atoi((char *)p_enc + 8)) == 0)
- return e_invarg;
+ return e_invalid_argument;
#else
// Unix: accept any "2byte-" name, assume current locale.
enc_dbcs_new = DBCS_2BYTE;
@@ -563,7 +563,7 @@
}
}
else // Don't know what encoding this is, reject it.
- return e_invarg;
+ return e_invalid_argument;
if (enc_dbcs_new != 0)
{