MCPcopy Index your code
hub / github.com/sql-js/sql.js / _dotlockLock

Function _dotlockLock

js/sql-debug.js:17370–17416  ·  view source on GitHub ↗
($0,$1)

Source from the content-addressed store, hash-verified

17368 return (0)|0;
17369}
17370function _dotlockLock($0,$1) {
17371 $0 = $0|0;
17372 $1 = $1|0;
17373 var $$0 = 0, $$0$i$ph = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
17374 sp = STACKTOP;
17375 $2 = ((($0)) + 24|0);
17376 $3 = HEAP32[$2>>2]|0;
17377 $4 = ((($0)) + 16|0);
17378 $5 = HEAP8[$4>>0]|0;
17379 $6 = ($5<<24>>24)==(0);
17380 if (!($6)) {
17381 $7 = $1&255;
17382 HEAP8[$4>>0] = $7;
17383 (_utimes(($3|0),(0|0))|0);
17384 $$0 = 0;
17385 return ($$0|0);
17386 }
17387 $8 = HEAP32[(3640)>>2]|0;
17388 $9 = (FUNCTION_TABLE_iii[$8 & 255]($3,511)|0);
17389 $10 = ($9|0)<(0);
17390 if (!($10)) {
17391 $14 = $1&255;
17392 HEAP8[$4>>0] = $14;
17393 $$0 = $9;
17394 return ($$0|0);
17395 }
17396 $11 = (___errno_location()|0);
17397 $12 = HEAP32[$11>>2]|0;
17398 switch ($12|0) {
17399 case 1: {
17400 $$0$i$ph = 3;
17401 break;
17402 }
17403 case 37: case 4: case 16: case 110: case 11: case 13: case 17: {
17404 $$0 = 5;
17405 return ($$0|0);
17406 break;
17407 }
17408 default: {
17409 $$0$i$ph = 3850;
17410 }
17411 }
17412 $13 = ((($0)) + 20|0);
17413 HEAP32[$13>>2] = $12;
17414 $$0 = $$0$i$ph;
17415 return ($$0|0);
17416}
17417function _dotlockUnlock($0,$1) {
17418 $0 = $0|0;
17419 $1 = $1|0;

Callers

nothing calls this directly

Calls 2

___errno_locationFunction · 0.85
_utimesFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…