[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[hurd] 39/70: libnetfs: register libnetfs-based translators as important
From: |
Samuel Thibault |
Subject: |
[hurd] 39/70: libnetfs: register libnetfs-based translators as important |
Date: |
Mon, 16 Sep 2013 07:41:41 +0000 |
This is an automated email from the git hooks/post-receive script.
sthibault pushed a commit to branch upstream
in repository hurd.
commit 5b7ec73d4a310b2ca8322124285a22bad56286d5
Author: Justus Winter <address@hidden>
Date: Thu Aug 15 09:38:00 2013 +0200
libnetfs: register libnetfs-based translators as important
Register libnetfs-based translators running as root as important
processes at the proc server.
* libnetfs/init-startup.c (netfs_startup): Mark us as important.
---
libnetfs/init-startup.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/libnetfs/init-startup.c b/libnetfs/init-startup.c
index 2e0f43a..e17c4f1 100644
--- a/libnetfs/init-startup.c
+++ b/libnetfs/init-startup.c
@@ -48,5 +48,19 @@ netfs_startup (mach_port_t bootstrap, int flags)
mach_port_deallocate (mach_task_self (), bootstrap);
+ /* Mark us as important. */
+ mach_port_t proc = getproc ();
+ if (proc == MACH_PORT_NULL)
+ error (12, err, "Translator startup failure: getproc");
+
+ err = proc_mark_important (proc);
+
+ /* This might fail due to permissions or because the old proc server
+ is still running, ignore any such errors. */
+ if (err && err != EPERM && err != EMIG_BAD_ID)
+ error (13, err, "Translator startup failure: proc_mark_important");
+
+ mach_port_deallocate (mach_task_self (), proc);
+
return realnode;
}
--
Alioth's /usr/local/bin/git-commit-notice on
/srv/git.debian.org/git/pkg-hurd/hurd.git
- [hurd] 48/70: exec: keep track of the range where executable segments are mapped, (continued)
- [hurd] 48/70: exec: keep track of the range where executable segments are mapped, Samuel Thibault, 2013/09/16
- [hurd] 64/70: hurd: add fsys_get_source, Samuel Thibault, 2013/09/16
- [hurd] 59/70: hurd: add fsys_get_children, Samuel Thibault, 2013/09/16
- [hurd] 68/70: Handle notification on page eviction, Samuel Thibault, 2013/09/16
- [hurd] 65/70: trans: add mtab translator, Samuel Thibault, 2013/09/16
- [hurd] 49/70: proc: remove unused file exc-reply.defs, Samuel Thibault, 2013/09/16
- [hurd] 47/70: hurd: add proc_{get,set}_code, Samuel Thibault, 2013/09/16
- [hurd] 44/70: mount: handle -t auto, Samuel Thibault, 2013/09/16
- [hurd] 55/70: libdiskfs: add fsys_get_children, Samuel Thibault, 2013/09/16
- [hurd] 18/70: libshouldbeinlibc: Add nullauth.{c,h}, Samuel Thibault, 2013/09/16
- [hurd] 39/70: libnetfs: register libnetfs-based translators as important,
Samuel Thibault <=
- [hurd] 51/70: libihash: add HURD_IHASH_ITERATE_ITEMS macro, Samuel Thibault, 2013/09/16
- [hurd] 15/70: Define and use symbolic names for important processes, Samuel Thibault, 2013/09/16
- [hurd] 52/70: libdiskfs: track file name in struct peropen, Samuel Thibault, 2013/09/16
- [hurd] 50/70: proc: Remove unused declaration of zombie_list, Samuel Thibault, 2013/09/16
- [hurd] 31/70: Merge branch 'master-merge2' into master-merge, Samuel Thibault, 2013/09/16
- [hurd] 12/70: umount: add a umount utility, Samuel Thibault, 2013/09/16
- [hurd] 10/70: sutils: allow multiple entries for the device "none", Samuel Thibault, 2013/09/16
- [hurd] 08/70: mount: implement -O, --test-opts, Samuel Thibault, 2013/09/16
- [hurd] 07/70: mount: add -f and --fake arguments, Samuel Thibault, 2013/09/16
- [hurd] 11/70: sutils: fix the semantic of -t, --types in fstab.c, Samuel Thibault, 2013/09/16