Skip to content

Commit 9afb4d0

Browse files
committed
swapon.c: make use of RVAL_DECODED
* swapon.c (sys_swapon): Update for RVAL_DECODED.
1 parent 63bae23 commit 9afb4d0

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

swapon.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@
66

77
SYS_FUNC(swapon)
88
{
9-
if (entering(tcp)) {
10-
int flags = tcp->u_arg[1];
11-
printpath(tcp, tcp->u_arg[0]);
12-
tprints(", ");
13-
printflags(swap_flags, flags & ~SWAP_FLAG_PRIO_MASK,
14-
"SWAP_FLAG_???");
15-
if (flags & SWAP_FLAG_PREFER)
16-
tprintf("|%d", flags & SWAP_FLAG_PRIO_MASK);
17-
}
18-
return 0;
9+
int flags = tcp->u_arg[1];
10+
11+
printpath(tcp, tcp->u_arg[0]);
12+
tprints(", ");
13+
printflags(swap_flags, flags & ~SWAP_FLAG_PRIO_MASK,
14+
"SWAP_FLAG_???");
15+
if (flags & SWAP_FLAG_PREFER)
16+
tprintf("|%d", flags & SWAP_FLAG_PRIO_MASK);
17+
18+
return RVAL_DECODED;
1919
}

0 commit comments

Comments
 (0)