(node, newSize)
| 1617 | if (node.usedBytes > 0) node.contents.set(oldContents.subarray(0, node.usedBytes), 0); |
| 1618 | }, |
| 1619 | resizeFileStorage(node, newSize) { |
| 1620 | if (node.usedBytes == newSize) return; |
| 1621 | if (newSize == 0) { |
| 1622 | node.contents = null; |
| 1623 | node.usedBytes = 0; |
| 1624 | } else { |
| 1625 | var oldContents = node.contents; |
| 1626 | node.contents = new Uint8Array(newSize); |
| 1627 | if (oldContents) { |
| 1628 | node.contents.set(oldContents.subarray(0, Math.min(newSize, node.usedBytes))); |
| 1629 | } |
| 1630 | node.usedBytes = newSize; |
| 1631 | } |
| 1632 | }, |
| 1633 | node_ops: { |
| 1634 | getattr(node) { |
| 1635 | var attr = {}; |
nothing calls this directly
no outgoing calls
no test coverage detected