0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

updated for version 7.3.689

Problem:    MzScheme and Lua may use a NULL string.
Solution:   Use an empty string instead of NULL. (Yukihiro Nakadaira)
This commit is contained in:
Bram Moolenaar
2012-10-14 03:41:59 +02:00
parent 7bc4f93c07
commit d04da7cb4a
3 changed files with 6 additions and 2 deletions

View File

@@ -464,7 +464,8 @@ luaV_pushtypval(lua_State *L, typval_T *tv)
switch (tv->v_type)
{
case VAR_STRING:
lua_pushstring(L, (char *) tv->vval.v_string);
lua_pushstring(L, tv->vval.v_string == NULL
? "" : (char *)tv->vval.v_string);
break;
case VAR_NUMBER:
lua_pushinteger(L, (int) tv->vval.v_number);