git ssb

0+

wanderer🌟 / bls-lib



Commit 067dae5956ee6811ae781335f12ba2eb22196b69

remove writeStringToMem

Signed-off-by: wanderer <mjbecze@gmail.com>
wanderer committed on 9/18/2017, 8:41:28 PM
Parent: 4840ee04dd0bfe2f709a2be37fe16e6119a46e90

Files changed

index.jschanged
package-lock.jsonchanged
package.jsonchanged
index.jsView
@@ -185,16 +185,16 @@
185185
186186 function wrapInput (func, returnValue = false) {
187187 return function () {
188188 const args = [...arguments]
189- const buf = args.pop()
189 + let buf = args.pop()
190190 const ioMode = 0
191191 const pos = mod._malloc(buf.length)
192192 if (typeof buf === 'string') {
193- mod.writeStringToMemory(buf, pos)
194- } else {
195- mod.HEAP8.set(buf, pos)
193 + buf = Buffer.from(buf)
196194 }
195 +
196 + mod.HEAP8.set(buf, pos)
197197 let r = func(...args, pos, buf.length, ioMode)
198198 mod._free(pos)
199199 if (returnValue) return r
200200 }
package-lock.jsonView
The diff is too large to show. Use a local git client to view these changes.
Old file size: 250918 bytes
New file size: 250779 bytes
package.jsonView
@@ -14,9 +14,11 @@
1414 ""
1515 ],
1616 "author": "mjbecze <mjbecze@gmail.com>",
1717 "license": "MPL-2.0",
18- "dependencies": {},
18 + "dependencies": {
19 + "defined": "^1.0.0"
20 + },
1921 "devDependencies": {
2022 "array-shuffle": "^1.0.1",
2123 "coveralls": "^2.11.4",
2224 "documentation": "^5.2.0",

Built with git-ssb-web