(bytes)
| 6412 | } |
| 6413 | |
| 6414 | function computeCheckSum(bytes) { |
| 6415 | while (bytes.length % 4 !== 0) { |
| 6416 | bytes.push(0); |
| 6417 | } |
| 6418 | |
| 6419 | var sum = 0; |
| 6420 | for (var i = 0; i < bytes.length; i += 4) { |
| 6421 | sum += (bytes[i] << 24) + |
| 6422 | (bytes[i + 1] << 16) + |
| 6423 | (bytes[i + 2] << 8) + |
| 6424 | (bytes[i + 3]); |
| 6425 | } |
| 6426 | |
| 6427 | sum %= Math.pow(2, 32); |
| 6428 | return sum; |
| 6429 | } |
| 6430 | |
| 6431 | function makeTableRecord(tag, checkSum, offset, length) { |
| 6432 | return new table.Table('Table Record', [ |
no outgoing calls
no test coverage detected