diff src/quickfix.c @ 418:84825cc6f049

updated for version 7.0109
author vimboss
date Mon, 18 Jul 2005 21:47:53 +0000
parents c60ba877860b
children 7472c565592a
line wrap: on
line diff
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -443,7 +443,8 @@ qf_init_ext(efile, buf, errorformat, new
 	{
 	    if (buflnum > lnumlast)
 		break;
-	    STRNCPY(IObuff, ml_get_buf(buf, buflnum++, FALSE), CMDBUFFSIZE - 2);
+	    vim_strncpy(IObuff, ml_get_buf(buf, buflnum++, FALSE),
+							     CMDBUFFSIZE - 2);
 	}
 	else if (fgets((char *)IObuff, CMDBUFFSIZE - 2, fd) == NULL)
 	    break;
@@ -516,8 +517,7 @@ restofline:
 		else if ((i = (int)fmt_ptr->addr[5]) > 0)	/* %m */
 		{
 		    len = (int)(regmatch.endp[i] - regmatch.startp[i]);
-		    STRNCPY(errmsg, regmatch.startp[i], len);
-		    errmsg[len] = NUL;
+		    vim_strncpy(errmsg, regmatch.startp[i], len);
 		}
 		if ((i = (int)fmt_ptr->addr[6]) > 0)		/* %r */
 		    tail = regmatch.startp[i];