1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-27 20:41:58 +03:00

Rename wasm.cstringToJs() to wasm.cstrToJs() for consistency with other wasm.cstr... APIs.

FossilOrigin-Name: cbf483ea0ba3e6dc08ad7ed654380f818544b4c3cedfdb8aa848a83298268ceb
This commit is contained in:
stephan
2022-12-06 08:46:39 +00:00
parent 671386c637
commit 75435f8b2d
8 changed files with 39 additions and 39 deletions

View File

@ -803,7 +803,7 @@ const installOpfsVfs = function callee(options){
const vfsSyncWrappers = {
xAccess: function(pVfs,zName,flags,pOut){
mTimeStart('xAccess');
const rc = opRun('xAccess', wasm.cstringToJs(zName));
const rc = opRun('xAccess', wasm.cstrToJs(zName));
wasm.setMemValue( pOut, (rc ? 0 : 1), 'i32' );
mTimeEnd();
return 0;
@ -823,7 +823,7 @@ const installOpfsVfs = function callee(options){
},
xDelete: function(pVfs, zName, doSyncDir){
mTimeStart('xDelete');
opRun('xDelete', wasm.cstringToJs(zName), doSyncDir, false);
opRun('xDelete', wasm.cstrToJs(zName), doSyncDir, false);
/* We're ignoring errors because we cannot yet differentiate
between harmless and non-harmless failures. */
mTimeEnd();
@ -855,7 +855,7 @@ const installOpfsVfs = function callee(options){
C-string here. */
opfsFlags |= state.opfsFlags.OPFS_UNLOCK_ASAP;
}
zName = wasm.cstringToJs(zName);
zName = wasm.cstrToJs(zName);
}
const fh = Object.create(null);
fh.fid = pFile;
@ -1231,7 +1231,7 @@ const installOpfsVfs = function callee(options){
const readBuf = wasm.scopedAlloc(16);
rc = ioSyncWrappers.xRead(sq3File.pointer, readBuf, 6, 2);
wasm.setMemValue(readBuf+6,0);
let jRead = wasm.cstringToJs(readBuf);
let jRead = wasm.cstrToJs(readBuf);
log("xRead() got:",jRead);
if("sanity"!==jRead) toss("Unexpected xRead() value.");
if(vfsSyncWrappers.xSleep){