diff src/vim.h @ 3549:f52d2ea0f81c v7.3.535

updated for version 7.3.535 Problem: Many #ifdefs for MB_MAXBYTES. Solution: Also define MB_MAXBYTES without the +multi_byte feature. Fix places where the buffer didn't include space for a NUL byte.
author Bram Moolenaar <bram@vim.org>
date Fri, 01 Jun 2012 15:21:02 +0200
parents 7e4428115d2c
children 09d0bda69df0
line wrap: on
line diff
--- a/src/vim.h
+++ b/src/vim.h
@@ -1703,6 +1703,8 @@ int vim_memcmp __ARGS((void *, void *, s
  * character of up to 6 bytes, or one 16-bit character of up to three bytes
  * plus six following composing characters of three bytes each. */
 # define MB_MAXBYTES	21
+#else
+# define MB_MAXBYTES	1
 #endif
 
 #if (defined(FEAT_PROFILE) || defined(FEAT_RELTIME)) && !defined(PROTO)
@@ -2017,6 +2019,7 @@ typedef int VimClipboard;	/* This is req
  #pragma warning(disable : 4312)
 #endif
 
+/* Note: a NULL argument for vim_realloc() is not portable, don't use it. */
 #if defined(MEM_PROFILE)
 # define vim_realloc(ptr, size)  mem_realloc((ptr), (size))
 #else