Lines Matching refs:FS
1527 var path = (i >= 0) ? arguments[i] : FS.cwd();
1597 FS.registerDevice(dev, TTY.stream_ops);
1601 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
1612 throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
1620 throw new FS.ErrnoError(ERRNO_CODES.EIO);
1623 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
1635 throw new FS.ErrnoError(ERRNO_CODES.ENXIO);
1641 throw new FS.ErrnoError(ERRNO_CODES.EIO);
1698 if (FS.isBlkdev(mode) || FS.isFIFO(mode)) {
1700 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
1746 stream: FS.chrdev_stream_ops
1750 var node = FS.createNode(parent, name, mode, dev);
1751 if (FS.isDir(node.mode)) {
1755 } else if (FS.isFile(node.mode)) {
1760 } else if (FS.isLink(node.mode)) {
1763 } else if (FS.isChrdev(node.mode)) {
1782 attr.dev = FS.isChrdev(node.mode) ? node.id : 1;
1789 if (FS.isDir(node.mode)) {
1791 } else if (FS.isFile(node.mode)) {
1793 } else if (FS.isLink(node.mode)) {
1820 throw FS.genericErrors[ERRNO_CODES.ENOENT];
1825 if (FS.isDir(old_node.mode)) {
1828 new_node = FS.lookupNode(new_dir, new_name);
1833 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
1845 var node = FS.lookupNode(parent, name);
1847 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
1864 if (!FS.isLink(node.mode)) {
1865 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
1910 if (FS.isFile(stream.node.mode)) {
1915 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
1926 if (!FS.isFile(stream.node.mode)) {
1927 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
1951 throw new FS.ErrnoError(ERRNO_CODES.ENOMEM);
2025 … var check = FS.readdir(mount.mountpoint).filter(isRealDir).map(toAbsolute(mount.mountpoint));
2032 stat = FS.stat(path);
2037 if (FS.isDir(stat.mode)) {
2038 check.push.apply(check, FS.readdir(path).filter(isRealDir).map(toAbsolute(path)));
2073 var lookup = FS.lookupPath(path);
2075 stat = FS.stat(path);
2080 if (FS.isDir(stat.mode)) {
2082 } else if (FS.isFile(stat.mode)) {
2089 if (FS.isDir(entry.mode)) {
2090 FS.mkdir(path, entry.mode);
2091 } else if (FS.isFile(entry.mode)) {
2092 FS.writeFile(path, entry.contents, { encoding: 'binary', canOwn: true });
2097 FS.utime(path, entry.timestamp, entry.timestamp);
2105 var lookup = FS.lookupPath(path);
2106 var stat = FS.stat(path);
2108 if (FS.isDir(stat.mode)) {
2109 FS.rmdir(path);
2110 } else if (FS.isFile(stat.mode)) {
2111 FS.unlink(path);
2211 if (!FS.isDir(mode) && !FS.isFile(mode) && !FS.isLink(mode)) {
2212 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
2214 var node = FS.createNode(parent, name, mode);
2229 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2254 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2296 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2307 if (FS.isDir(node.mode)) {
2314 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2324 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2332 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2340 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2348 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2356 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2364 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2369 if (FS.isFile(stream.node.mode)) {
2374 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2378 if (FS.isFile(stream.node.mode) && stream.nfd) {
2383 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2392 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2407 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2415 if (FS.isFile(stream.node.mode)) {
2420 throw new FS.ErrnoError(ERRNO_CODES[e.code]);
2426 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
2443 …}var FS={root:null,mounts:[],devices:[null],streams:[],nextInode:1,nameTable:null,currentPath:"/",… variable
2444 if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + stackTrace();
2447 path = PATH.resolve(FS.cwd(), path);
2461 throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
2470 var current = FS.root;
2480 current = FS.lookupNode(current, parts[i]);
2484 if (FS.isMountpoint(current)) {
2494 while (FS.isLink(current.mode)) {
2495 var link = FS.readlink(current_path);
2498 var lookup = FS.lookupPath(current_path, { recurse_count: opts.recurse_count });
2502 throw new FS.ErrnoError(ERRNO_CODES.ELOOP);
2512 if (FS.isRoot(node)) {
2527 return ((parentid + hash) >>> 0) % FS.nameTable.length;
2529 var hash = FS.hashName(node.parent.id, node.name);
2530 node.name_next = FS.nameTable[hash];
2531 FS.nameTable[hash] = node;
2533 var hash = FS.hashName(node.parent.id, node.name);
2534 if (FS.nameTable[hash] === node) {
2535 FS.nameTable[hash] = node.name_next;
2537 var current = FS.nameTable[hash];
2547 var err = FS.mayLookup(parent);
2549 throw new FS.ErrnoError(err);
2551 var hash = FS.hashName(parent.id, name);
2552 for (var node = FS.nameTable[hash]; node; node = node.name_next) {
2559 return FS.lookup(parent, name);
2561 if (!FS.FSNode) {
2562 FS.FSNode = function(parent, name, mode, rdev) {
2569 this.id = FS.nextInode++;
2577 FS.FSNode.prototype = {};
2585 Object.defineProperties(FS.FSNode.prototype, {
2595 get: function() { return FS.isDir(this.mode); },
2598 get: function() { return FS.isChrdev(this.mode); },
2603 var node = new FS.FSNode(parent, name, mode, rdev);
2605 FS.hashAddNode(node);
2609 FS.hashRemoveNode(node);
2629 var flags = FS.flagModes[str];
2642 if (FS.ignorePermissions) {
2655 return FS.nodePermissions(dir, 'x');
2658 var node = FS.lookupNode(dir, name);
2662 return FS.nodePermissions(dir, 'wx');
2666 node = FS.lookupNode(dir, name);
2670 var err = FS.nodePermissions(dir, 'wx');
2675 if (!FS.isDir(node.mode)) {
2678 if (FS.isRoot(node) || FS.getPath(node) === FS.cwd()) {
2682 if (FS.isDir(node.mode)) {
2691 if (FS.isLink(node.mode)) {
2693 } else if (FS.isDir(node.mode)) {
2699 return FS.nodePermissions(node, FS.flagsToPermissionString(flags));
2702 fd_end = fd_end || FS.MAX_OPEN_FDS;
2704 if (!FS.streams[fd]) {
2708 throw new FS.ErrnoError(ERRNO_CODES.EMFILE);
2710 return FS.streams[fd];
2712 if (!FS.FSStream) {
2713 FS.FSStream = function(){};
2714 FS.FSStream.prototype = {};
2716 Object.defineProperties(FS.FSStream.prototype, {
2734 stream.__proto__ = FS.FSStream.prototype;
2736 var newStream = new FS.FSStream();
2742 var fd = FS.nextfd(fd_start, fd_end);
2744 FS.streams[fd] = stream;
2747 FS.streams[fd] = null;
2749 return FS.streams[ptr - 1];
2753 var device = FS.getDevice(stream.node.rdev);
2761 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
2769 FS.devices[dev] = { stream_ops: ops };
2771 return FS.devices[dev];
2791 var mounts = FS.getMounts(FS.root.mount);
2819 if (root && FS.root) {
2820 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
2822 var lookup = FS.lookupPath(mountpoint, { follow_mount: false });
2827 if (FS.isMountpoint(node)) {
2828 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
2831 if (!FS.isDir(node.mode)) {
2832 throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
2849 FS.root = mountRoot;
2862 var lookup = FS.lookupPath(mountpoint, { follow_mount: false });
2864 if (!FS.isMountpoint(lookup.node)) {
2865 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
2871 var mounts = FS.getMounts(mount);
2873 Object.keys(FS.nameTable).forEach(function (hash) {
2874 var current = FS.nameTable[hash];
2880 FS.destroyNode(current);
2897 var lookup = FS.lookupPath(path, { parent: true });
2900 var err = FS.mayCreate(parent, name);
2902 throw new FS.ErrnoError(err);
2905 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
2912 return FS.mknod(path, mode, 0);
2917 return FS.mknod(path, mode, 0);
2924 return FS.mknod(path, mode, dev);
2926 var lookup = FS.lookupPath(newpath, { parent: true });
2929 var err = FS.mayCreate(parent, newname);
2931 throw new FS.ErrnoError(err);
2934 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
2945 lookup = FS.lookupPath(old_path, { parent: true });
2947 lookup = FS.lookupPath(new_path, { parent: true });
2950 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
2954 throw new FS.ErrnoError(ERRNO_CODES.EXDEV);
2957 var old_node = FS.lookupNode(old_dir, old_name);
2961 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
2966 throw new FS.ErrnoError(ERRNO_CODES.ENOTEMPTY);
2971 new_node = FS.lookupNode(new_dir, new_name);
2980 var isdir = FS.isDir(old_node.mode);
2981 var err = FS.mayDelete(old_dir, old_name, isdir);
2983 throw new FS.ErrnoError(err);
2988 FS.mayDelete(new_dir, new_name, isdir) :
2989 FS.mayCreate(new_dir, new_name);
2991 throw new FS.ErrnoError(err);
2994 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
2996 if (FS.isMountpoint(old_node) || (new_node && FS.isMountpoint(new_node))) {
2997 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
3001 err = FS.nodePermissions(old_dir, 'w');
3003 throw new FS.ErrnoError(err);
3007 FS.hashRemoveNode(old_node);
3016 FS.hashAddNode(old_node);
3019 var lookup = FS.lookupPath(path, { parent: true });
3022 var node = FS.lookupNode(parent, name);
3023 var err = FS.mayDelete(parent, name, true);
3025 throw new FS.ErrnoError(err);
3028 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3030 if (FS.isMountpoint(node)) {
3031 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
3034 FS.destroyNode(node);
3036 var lookup = FS.lookupPath(path, { follow: true });
3039 throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
3043 var lookup = FS.lookupPath(path, { parent: true });
3046 var node = FS.lookupNode(parent, name);
3047 var err = FS.mayDelete(parent, name, false);
3051 throw new FS.ErrnoError(err);
3054 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3056 if (FS.isMountpoint(node)) {
3057 throw new FS.ErrnoError(ERRNO_CODES.EBUSY);
3060 FS.destroyNode(node);
3062 var lookup = FS.lookupPath(path);
3065 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3069 var lookup = FS.lookupPath(path, { follow: !dontFollow });
3072 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3076 return FS.stat(path, true);
3080 var lookup = FS.lookupPath(path, { follow: !dontFollow });
3086 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3093 FS.chmod(path, mode, true);
3095 var stream = FS.getStream(fd);
3097 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3099 FS.chmod(stream.node, mode);
3103 var lookup = FS.lookupPath(path, { follow: !dontFollow });
3109 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3116 FS.chown(path, uid, gid, true);
3118 var stream = FS.getStream(fd);
3120 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3122 FS.chown(stream.node, uid, gid);
3125 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3129 var lookup = FS.lookupPath(path, { follow: true });
3135 throw new FS.ErrnoError(ERRNO_CODES.EPERM);
3137 if (FS.isDir(node.mode)) {
3138 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
3140 if (!FS.isFile(node.mode)) {
3141 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3143 var err = FS.nodePermissions(node, 'w');
3145 throw new FS.ErrnoError(err);
3152 var stream = FS.getStream(fd);
3154 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3157 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3159 FS.truncate(stream.node, len);
3161 var lookup = FS.lookupPath(path, { follow: true });
3167 flags = typeof flags === 'string' ? FS.modeStringToFlags(flags) : flags;
3180 var lookup = FS.lookupPath(path, {
3193 throw new FS.ErrnoError(ERRNO_CODES.EEXIST);
3197 node = FS.mknod(path, mode, 0);
3201 throw new FS.ErrnoError(ERRNO_CODES.ENOENT);
3204 if (FS.isChrdev(node.mode)) {
3208 var err = FS.mayOpen(node, flags);
3210 throw new FS.ErrnoError(err);
3214 FS.truncate(node, 0);
3220 var stream = FS.createStream({
3222 path: FS.getPath(node), // we want the absolute path to the node
3236 if (!FS.readFiles) FS.readFiles = {};
3237 if (!(path in FS.readFiles)) {
3238 FS.readFiles[path] = 1;
3251 FS.closeStream(stream.fd);
3255 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
3260 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3263 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3265 if (FS.isDir(stream.node.mode)) {
3266 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
3269 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3276 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
3283 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3286 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3288 if (FS.isDir(stream.node.mode)) {
3289 throw new FS.ErrnoError(ERRNO_CODES.EISDIR);
3292 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3299 throw new FS.ErrnoError(ERRNO_CODES.ESPIPE);
3303 FS.llseek(stream, 0, 2);
3310 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
3313 throw new FS.ErrnoError(ERRNO_CODES.EBADF);
3315 if (!FS.isFile(stream.node.mode) && !FS.isDir(node.mode)) {
3316 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
3319 throw new FS.ErrnoError(ERRNO_CODES.EOPNOTSUPP);
3325 throw new FS.ErrnoError(ERRNO_CODES.EACCES);
3328 throw new FS.ErrnoError(ERRNO_CODES.ENODEV);
3333 throw new FS.ErrnoError(ERRNO_CODES.ENOTTY);
3344 var stream = FS.open(path, opts.flags);
3345 var stat = FS.stat(path);
3348 FS.read(stream, buf, 0, length, 0);
3358 FS.close(stream);
3367 var stream = FS.open(path, opts.flags, opts.mode);
3371 FS.write(stream, buf, 0, buf.length, 0, opts.canOwn);
3373 FS.write(stream, data, 0, data.length, 0, opts.canOwn);
3375 FS.close(stream);
3377 return FS.currentPath;
3379 var lookup = FS.lookupPath(path, { follow: true });
3380 if (!FS.isDir(lookup.node.mode)) {
3381 throw new FS.ErrnoError(ERRNO_CODES.ENOTDIR);
3383 var err = FS.nodePermissions(lookup.node, 'x');
3385 throw new FS.ErrnoError(err);
3387 FS.currentPath = lookup.path;
3389 FS.mkdir('/tmp');
3392 FS.mkdir('/dev');
3394 FS.registerDevice(FS.makedev(1, 3), {
3398 FS.mkdev('/dev/null', FS.makedev(1, 3));
3402 TTY.register(FS.makedev(5, 0), TTY.default_tty_ops);
3403 TTY.register(FS.makedev(6, 0), TTY.default_tty1_ops);
3404 FS.mkdev('/dev/tty', FS.makedev(5, 0));
3405 FS.mkdev('/dev/tty1', FS.makedev(6, 0));
3408 FS.mkdir('/dev/shm');
3409 FS.mkdir('/dev/shm/tmp');
3420 FS.createDevice('/dev', 'stdin', Module['stdin']);
3422 FS.symlink('/dev/tty', '/dev/stdin');
3425 FS.createDevice('/dev', 'stdout', null, Module['stdout']);
3427 FS.symlink('/dev/tty', '/dev/stdout');
3430 FS.createDevice('/dev', 'stderr', null, Module['stderr']);
3432 FS.symlink('/dev/tty1', '/dev/stderr');
3436 var stdin = FS.open('/dev/stdin', 'r');
3437 HEAP32[((_stdin)>>2)]=FS.getPtrForStream(stdin);
3440 var stdout = FS.open('/dev/stdout', 'w');
3441 HEAP32[((_stdout)>>2)]=FS.getPtrForStream(stdout);
3444 var stderr = FS.open('/dev/stderr', 'w');
3445 HEAP32[((_stderr)>>2)]=FS.getPtrForStream(stderr);
3448 if (FS.ErrnoError) return;
3449 FS.ErrnoError = function ErrnoError(errno) {
3459 FS.ErrnoError.prototype = new Error();
3460 FS.ErrnoError.prototype.constructor = FS.ErrnoError;
3463 FS.genericErrors[code] = new FS.ErrnoError(code);
3464 FS.genericErrors[code].stack = '<generic error, no stack>';
3467 FS.ensureErrnoError();
3469 FS.nameTable = new Array(4096);
3471 FS.mount(MEMFS, {}, '/');
3473 FS.createDefaultDirectories();
3474 FS.createDefaultDevices();
3476 …assert(!FS.init.initialized, 'FS.init was previously called. If you want to initialize later with …
3477 FS.init.initialized = true;
3479 FS.ensureErrnoError();
3486 FS.createStandardStreams();
3488 FS.init.initialized = false;
3489 for (var i = 0; i < FS.streams.length; i++) {
3490 var stream = FS.streams[i];
3494 FS.close(stream);
3510 var ret = FS.analyzePath(path, dontResolveLastLink);
3520 var lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
3529 var lookup = FS.lookupPath(path, { parent: true });
3534 lookup = FS.lookupPath(path, { follow: !dontResolveLastLink });
3545 var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
3546 var mode = FS.getMode(canRead, canWrite);
3547 return FS.mkdir(path, mode);
3549 parent = typeof parent === 'string' ? parent : FS.getPath(parent);
3556 FS.mkdir(current);
3564 var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
3565 var mode = FS.getMode(canRead, canWrite);
3566 return FS.create(path, mode);
3568 …var path = name ? PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name) : par…
3569 var mode = FS.getMode(canRead, canWrite);
3570 var node = FS.create(path, mode);
3578 FS.chmod(node, mode | 146);
3579 var stream = FS.open(node, 'w');
3580 FS.write(stream, data, 0, data.length, 0, canOwn);
3581 FS.close(stream);
3582 FS.chmod(node, mode);
3586 var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
3587 var mode = FS.getMode(!!input, !!output);
3588 if (!FS.createDevice.major) FS.createDevice.major = 64;
3589 var dev = FS.makedev(FS.createDevice.major++, 0);
3592 FS.registerDevice(dev, {
3609 throw new FS.ErrnoError(ERRNO_CODES.EIO);
3612 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
3628 throw new FS.ErrnoError(ERRNO_CODES.EIO);
3637 return FS.mkdev(path, mode, dev);
3639 var path = PATH.join2(typeof parent === 'string' ? parent : FS.getPath(parent), name);
3640 return FS.symlink(target, path);
3755 var node = FS.createFile(parent, name, properties, canRead, canWrite);
3771 if (!FS.forceLoadFile(node)) {
3772 throw new FS.ErrnoError(ERRNO_CODES.EIO);
3779 if (!FS.forceLoadFile(node)) {
3780 throw new FS.ErrnoError(ERRNO_CODES.EIO);
3808 FS.createDataFile(parent, name, byteArray, canRead, canWrite, canOwn);
3841 var indexedDB = FS.indexedDB();
3843 var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
3850 db.createObjectStore(FS.DB_STORE_NAME);
3854 var transaction = db.transaction([FS.DB_STORE_NAME], 'readwrite');
3855 var files = transaction.objectStore(FS.DB_STORE_NAME);
3861 var putRequest = files.put(FS.analyzePath(path).object.contents, path);
3871 var indexedDB = FS.indexedDB();
3873 var openRequest = indexedDB.open(FS.DB_NAME(), FS.DB_VERSION);
3881 var transaction = db.transaction([FS.DB_STORE_NAME], 'readonly');
3886 var files = transaction.objectStore(FS.DB_STORE_NAME);
3894 if (FS.analyzePath(path).exists) {
3895 FS.unlink(path);
3897 … FS.createDataFile(PATH.dirname(path), PATH.basename(path), getRequest.result, true, true, true);
3912 return FS.createNode(null, '/', 16384 | 511 /* 0777 */, 0);
3933 var node = FS.createNode(SOCKFS.root, name, 49152, 0);
3938 var stream = FS.createStream({
3941 flags: FS.modeStringToFlags('r+'),
3952 var stream = FS.getStream(fd);
3953 if (!stream || !FS.isSocket(stream.node.mode)) {
4050 throw new FS.ErrnoError(ERRNO_CODES.EHOSTUNREACH);
4204 throw new FS.ErrnoError(ERRNO_CODES.EINVAL); // already bound
4222 if (!(e instanceof FS.ErrnoError)) throw e;
4228 throw new FS.ErrnoError(ERRNO_CODS.EOPNOTSUPP);
4240 throw new FS.ErrnoError(ERRNO_CODES.EALREADY);
4242 throw new FS.ErrnoError(ERRNO_CODES.EISCONN);
4254 throw new FS.ErrnoError(ERRNO_CODES.EINPROGRESS);
4257 throw new FS.ErrnoError(ERRNO_CODES.EOPNOTSUPP);
4260 throw new FS.ErrnoError(ERRNO_CODES.EINVAL); // already listening
4296 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
4305 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
4326 throw new FS.ErrnoError(ERRNO_CODES.EDESTADDRREQ);
4340 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
4342 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
4375 throw new FS.ErrnoError(ERRNO_CODES.EINVAL);
4381 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
4391 throw new FS.ErrnoError(ERRNO_CODES.ENOTCONN);
4399 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
4402 throw new FS.ErrnoError(ERRNO_CODES.EAGAIN);
4440 var stream = FS.getStream(fildes);
4447 return FS.write(stream, slab, buf, nbyte, offset);
4449 FS.handleFSError(e);
4455 var stream = FS.getStream(fildes);
4464 return FS.write(stream, slab, buf, nbyte);
4466 FS.handleFSError(e);
4474 stream = FS.getStreamFromPtr(stream);
4485 var streamObj = FS.getStreamFromPtr(stream);
4911 var streamObj = FS.getStreamFromPtr(stream);
5635 FS.staticInit();__ATINIT__.unshift({ func: function() { if (!Module["noFSInit"] && !FS.init.initial…
5639 __ATINIT__.push({ func: function() { SOCKFS.root = FS.mount(SOCKFS, {}, null); } });