Wrote uname function
This commit is contained in:
parent
9c8ba82546
commit
a06d3c56a8
1 changed files with 9 additions and 0 deletions
9
misc/uname.c
Normal file
9
misc/uname.c
Normal file
|
@ -0,0 +1,9 @@
|
|||
#include <sys/utsname.h>
|
||||
#include <kernel/syscall.h>
|
||||
#include <unistd.h>
|
||||
|
||||
int uname(struct utsname * u) {
|
||||
__syscall_uname(u);
|
||||
gethostname(u->nodename, 70);
|
||||
return 1;
|
||||
}
|
Loading…
Reference in a new issue