NUL terminate buffer from fgetln(3). From fgsch@OpenBSD.

This commit is contained in:
Juli Mallett 2006-01-01 22:59:54 +00:00
parent f22bf18027
commit b65bc26736

View File

@ -608,6 +608,7 @@ prompt(void)
(void)fclose(ttyfp);
return (0);
}
response[rsize - 1] = '\0';
match = regexec(&cre, response, 0, NULL, 0);
(void)fclose(ttyfp);
regfree(&cre);