afsd prints information to standard out for testing and debugging when the
-debug option is given. However, syscall tracing is emitted without trailing
newlines on all platforms except netbsd, creating an unreadable wall of text.
# afsd -debug
...
afsd: Forking 4 background daemons.
SScall(183, 28, 0)=0 183, 28, 6583200)=0 SScall(183, 28, 6583
200)=0 SScall(183, 28, 6583200)=0 SScall(183, 28, 6583200)=0 S
Scall(183, 28, 6583200)=0 SScall(183, 28, 6583200)=0 SScall(18
...
Make the syscall call tracing usable by printing each one on a separate line.
# afsd -deubg
...
afsd: Forking 4 background daemons.
SScall(183, 28, 0)=0 183, 28, 6583200)=0
SScall(183, 28, 6583200)=0
SScall(183, 28, 6583200)=0
...
Change-Id: Ic9208243c1e05352744fb6f575384e00d0e3e59c
Reviewed-on: https://gerrit.openafs.org/12385
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
printf("SScall(%d, %d, %d)=%d (%d, %s)\n", AFS_SYSCALL, AFSCALL_CALL,
(int)args->params[0], error, errno, s);
#else
- printf("SScall(%d, %d, %d)=%d ", AFS_SYSCALL, AFSCALL_CALL,
+ printf("SScall(%d, %d, %d)=%d\n", AFS_SYSCALL, AFSCALL_CALL,
(int)args->params[0], error);
#endif
}