have extended area start on an even byte.

This commit is contained in:
Christopher Jeffrey 2013-03-06 04:53:08 -06:00
parent b664a21cdd
commit 00b5a5b6f7
1 changed files with 5 additions and 0 deletions

View File

@ -230,7 +230,12 @@ Tput.prototype.parseTerminfo = function(data) {
// Extended Header
if (this.extended) {
i--;
i += h.strTableSize;
if (i % 2) {
assert.equal(data[i], 0);
i++;
}
l = data.length;
if (i < l - 1) {
var extended = this.parseExtended(data.slice(i));