@@ -348,7 +348,7 @@ backend_t wasmfs_get_backend_by_path(const char* path) {
348
348
static timespec ms_to_timespec (double ms) {
349
349
long long seconds = ms / 1000 ;
350
350
timespec ts;
351
- ts.tv_sec = seconds; // seconds
351
+ ts.tv_sec = seconds; // seconds
352
352
ts.tv_nsec = (ms - (seconds * 1000 )) * 1000 * 1000 ; // nanoseconds
353
353
return ts;
354
354
}
@@ -357,7 +357,10 @@ static double timespec_to_ms(timespec ts) {
357
357
return double (ts.tv_sec ) * 1000 + double (ts.tv_nsec ) / (1000 * 1000 );
358
358
}
359
359
360
- int __syscall_newfstatat (int dirfd, const char * path, struct stat * buf, int flags) {
360
+ int __syscall_newfstatat (int dirfd,
361
+ const char * path,
362
+ struct stat * buf,
363
+ int flags) {
361
364
// Only accept valid flags.
362
365
if (flags & ~(AT_EMPTY_PATH | AT_NO_AUTOMOUNT | AT_SYMLINK_NOFOLLOW)) {
363
366
// TODO: Test this case.
@@ -600,8 +603,9 @@ int __syscall_mknodat(int dirfd, const char* path, mode_t mode, dev_t dev) {
600
603
OpenReturnMode::Nothing);
601
604
}
602
605
603
- static int
604
- doMkdir (path::ParsedParent parsed, mode_t mode, backend_t backend = NullBackend) {
606
+ static int doMkdir (path::ParsedParent parsed,
607
+ mode_t mode,
608
+ backend_t backend = NullBackend) {
605
609
if (auto err = parsed.getError ()) {
606
610
return err;
607
611
}
@@ -1077,7 +1081,9 @@ int __syscall_renameat(int olddirfd,
1077
1081
}
1078
1082
1079
1083
// TODO: Test this with non-AT_FDCWD values.
1080
- int __syscall_symlinkat (const char * target, int newdirfd, const char * linkpath) {
1084
+ int __syscall_symlinkat (const char * target,
1085
+ int newdirfd,
1086
+ const char * linkpath) {
1081
1087
auto parsed = path::parseParent (linkpath, newdirfd);
1082
1088
if (auto err = parsed.getError ()) {
1083
1089
return err;
@@ -1737,11 +1743,8 @@ int __syscall_fadvise64(int fd, off_t offset, off_t len, int advice) {
1737
1743
return 0 ;
1738
1744
}
1739
1745
1740
- int __syscall__newselect (int nfds,
1741
- void * readfds_,
1742
- void * writefds_,
1743
- void * exceptfds_,
1744
- void * timeout_) {
1746
+ int __syscall__newselect (
1747
+ int nfds, void * readfds_, void * writefds_, void * exceptfds_, void * timeout_) {
1745
1748
// TODO: Implement this syscall. For now, we return an error code,
1746
1749
// specifically ENOMEM which is valid per the docs:
1747
1750
// ENOMEM Unable to allocate memory for internal tables
0 commit comments