@zenfs/core 1.3.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/inode.js +2 -2
- package/package.json +1 -1
- package/src/inode.ts +2 -2
package/dist/inode.js
CHANGED
|
@@ -110,9 +110,9 @@ let Inode = (() => {
|
|
|
110
110
|
}
|
|
111
111
|
// Expand the buffer so it is the right size
|
|
112
112
|
if (buffer.byteLength < sz_inode) {
|
|
113
|
-
const newBuffer = new
|
|
113
|
+
const newBuffer = new Uint8Array(sz_inode);
|
|
114
114
|
// Fill the new buffer with current data
|
|
115
|
-
newBuffer.set(new
|
|
115
|
+
newBuffer.set(new Uint8Array(ArrayBuffer.isView(buffer) ? buffer.buffer : buffer));
|
|
116
116
|
/* Add a random ino.
|
|
117
117
|
This will be different from the actual one,
|
|
118
118
|
but `ino` isn't used anywhere so it should be fine.
|
package/package.json
CHANGED
package/src/inode.ts
CHANGED
|
@@ -25,9 +25,9 @@ export class Inode implements StatsLike {
|
|
|
25
25
|
|
|
26
26
|
// Expand the buffer so it is the right size
|
|
27
27
|
if (buffer.byteLength < sz_inode) {
|
|
28
|
-
const newBuffer = new
|
|
28
|
+
const newBuffer = new Uint8Array(sz_inode);
|
|
29
29
|
// Fill the new buffer with current data
|
|
30
|
-
newBuffer.set(new
|
|
30
|
+
newBuffer.set(new Uint8Array(ArrayBuffer.isView(buffer) ? buffer.buffer : buffer));
|
|
31
31
|
/* Add a random ino.
|
|
32
32
|
This will be different from the actual one,
|
|
33
33
|
but `ino` isn't used anywhere so it should be fine.
|