From: Enrico Scholz Date: Fri, 28 Nov 2003 23:11:20 +0000 (+0000) Subject: removed vc_chrootsafe(); such an implementation seems to be impossible... X-Git-Tag: version_0_26_90~25 X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=92904d50616f7f1f5031bfcc2e4a39be91206ef1;p=util-vserver.git removed vc_chrootsafe(); such an implementation seems to be impossible... updated vc_new_s_context documentation added vc_ctx_kill() prototype + doc git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/branches/SYSCALL_SWITCH@451 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- diff --git a/util-vserver/lib/vserver.h b/util-vserver/lib/vserver.h index 936f144..99ac26c 100644 --- a/util-vserver/lib/vserver.h +++ b/util-vserver/lib/vserver.h @@ -49,17 +49,15 @@ extern "C" { /** Puts current process into context , removes the given caps and * sets flags. * Special values for ctx are - * - -2 which means the current context (just for changing caps and flags) - * - -1 which means the next free context; this value can be used by - * ordinary users also */ + * - VC_SAMECTX which means the current context (just for changing caps and flags) + * - VC_RANDCTX which means the next free context; this value can be used by + * ordinary users also */ int vc_new_s_context(ctx_t ctx, unsigned int remove_cap, unsigned int flags); /** Sets the ipv4root information. * \precondition: nb<16 */ int vc_set_ipv4root(uint32_t bcast, size_t nb, struct vc_ip_mask_pair const *ips); - int vc_chrootsafe(char const *dir); - /* rlimit related functions */ typedef uint64_t vc_limit_t; @@ -81,6 +79,13 @@ extern "C" { int vc_get_rlimit(ctx_t ctx, int resource, struct vc_rlimit *lim); int vc_set_rlimit(ctx_t ctx, int resource, struct vc_rlimit const *lim); int vc_get_rlimit_mask(ctx_t ctx, struct vc_rlimit_mask *lim); + + + /** sends a signal to a context/pid + Special values for pid are: + * -1 which means every process in ctx except the init-process + * 0 which means every process in ctx inclusive the init-process */ + int vc_ctx_kill(ctx_t ctx, pid_t pid, int sig); /** Returns the context of the given process. pid==0 means the current process. */ ctx_t vc_X_getctx(pid_t pid);