view src/typemap @ 13109:fb1b162cdcf6 v8.0.1429

patch 8.0.1429: crash when calling term_start() with empty argument commit https://github.com/vim/vim/commit/ede35bbbd05306097bf3f4d603f2248ed1f4c5f1 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Jan 26 20:05:18 2018 +0100 patch 8.0.1429: crash when calling term_start() with empty argument Problem: Crash when calling term_start() with empty argument. Solution: Check for invalid argument. (Yasuhiro Matsomoto, closes https://github.com/vim/vim/issues/2503) Fix memory leak.
author Christian Brabandt <cb@256bit.org>
date Fri, 26 Jan 2018 20:15:06 +0100
parents dec4338a7da2
children
line wrap: on
line source

TYPEMAP
VIWIN	T_VIOBJNOMUNGE
VIBUF	T_VIOBJNOMUNGE

INPUT
T_VIOBJNOMUNGE
	if (sv_isa($arg, \"${ntype}\")) {
	    IV tmp = SvIV((SV*)SvRV($arg));
	    $var = INT2PTR($type, tmp);
	    if (!tmp)
		croak(\"$ntype no longer exists\");
	}
	else
	    croak(\"$var is not of type ${ntype}\")