2010/3/29 Denys Vlasenko <[email protected]>: > 2010/3/29 Jérémie Koenig <[email protected]>: (...)
> Too big. My version: > > /* We really don't care about people with domain names wider > than most screens */ > char buf[256]; > int r = getdomainname(buf, sizeof(buf)); > buf[sizeof(buf)-1] = '\0'; > return xstrdup(r < 0 ? "?" : buf); Ok, I get your point. I will try not to do it again :-) >> I have to admit that I was somewhat disturbed by the fact that >> getmntent_r() would silently truncate the record if the buffer was too >> small. > > Isn't it a bug in libc? Indeed. Though getmntent(3) does not specify this case, the glibc manual does document it as an error. I will try to look into this. >> (...) >> umount would never compile on Hurd, which does not have a umount() >> call at all. (Sorry, I should have been more explicit about this.) > > How they unmount filesystems? Hurd implements the filesystem as a series of "translator" processes. A filesystem is mounted by asking the parent translator to attach another process to one of its nodes. This way the filesystem code does not run in kernel mode, and a regular user can attach translators to their own files. A filesystem is unmounted by shutting down its translator. This is usually done with the 'settrans' command, though hurd includes a '(u)mount' utility as well. Ideally, a full-fledged busybox for Hurd would include these, but as far as my debian-installer port is concerned, I can probably start by pulling them from the hurd package. -- Jérémie Koenig <[email protected]> http://jk.fr.eu.org/ _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
