diff options
author | kay.sievers@vrfy.org <kay.sievers@vrfy.org> | 2004-10-18 20:51:13 -0700 |
---|---|---|
committer | Greg KH <gregkh@suse.de> | 2005-04-26 22:02:46 -0700 |
commit | 9cd1b46a138dbdd6c3fad2e23f88e34740b3a054 (patch) | |
tree | f833f5c2529e8cc86465168bf896f3d8d52701aa /klibc_fixups.c | |
parent | 1da6b0d0a71960f49e1ecf8bd9f1bc9e14c2b90e (diff) |
[PATCH] $local user
We once implemented the devfsd feature to set the owner of a device node
to the "local" user. This was before we had the dev.d/ scripts. We discussed
a similar issue with D-BUS recently and this should be better handled depending
on the distributions way to do such a thing.
I'm for removing this here as this can be easily covered by a dev.d/
script.
Here is the patch if nobody objects :)
Diffstat (limited to 'klibc_fixups.c')
-rw-r--r-- | klibc_fixups.c | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/klibc_fixups.c b/klibc_fixups.c index d1a452a449..e68ce22b50 100644 --- a/klibc_fixups.c +++ b/klibc_fixups.c @@ -125,38 +125,4 @@ struct group *getgrnam(const char *name) return &gr; } - -int ufd = -1; - -void setutent() -{ - if (ufd < 0) - ufd = open(UTMP_FILE, O_RDONLY); - fcntl(ufd, F_SETFD, FD_CLOEXEC); - lseek(ufd, 0, SEEK_SET); -} - -void endutent() { - if (ufd < 0) - return; - close(ufd); - ufd = -1; -} - -struct utmp *getutent(void) -{ - static struct utmp utmp; - int retval; - - if (ufd < 0) { - setutent(); - if (ufd < 0) - return NULL; - } - retval = read(ufd, &utmp, sizeof(struct utmp)); - if (retval < 1) - return NULL; - return &utmp; -} - #endif |