strcpy(runfile, argv[1]);
strcpy(runfile+len1, "/run");
- ctx=Evc_X_getctx(0);
+ ctx=Evc_get_task_xid(0);
if (ctx==0) {
WRITE_MSG(2, "save_ctxinfo: Can not operate in context 0\n");
while (*pid_str==' ') ++pid_str;
pid = atoi(pid_str);
- return vc_X_getctx(pid);
+ return vc_get_task_xid(pid);
}
static char const *
if (strcmp(argv[1], "--version")==0) showVersion();
}
- if (vc_X_getctx(0)!=1)
+ if (vc_get_task_xid(0)!=1)
Evc_new_s_context(1, vc_get_securecaps(), 0);
Epipe(p);
// open the process's status file to get the ctx number, and other stat
struct process_info *get_process_info(char *pid)
{
- int fd;
- char buffer[1024];
- char *p;
- size_t idx, l=strlen(pid);
- static struct process_info process;
+ int fd;
+ char buffer[1024];
+ char *p;
+ size_t idx, l=strlen(pid);
+ static struct process_info process;
- process.s_context = vc_X_getctx(atoi(pid));
+ process.s_context = vc_get_task_xid(atoi(pid));
memcpy(buffer, "/proc/", 6); idx = 6;
}
inline static UNUSED xid_t
-Evc_X_getctx(pid_t pid)
+Evc_get_task_xid(pid_t pid)
{
- register xid_t res = vc_X_getctx(pid);
- FatalErrnoError(res==VC_NOCTX, "vc_X_getctx()");
+ register xid_t res = vc_get_task_xid(pid);
+ FatalErrnoError(res==VC_NOCTX, "vc_get_task_xid()");
return res;
}
char buf[sizeof(int)*3+2];
xid_t ctx;
- if (argc==1) ctx = vc_X_getctx(0);
- else ctx = vc_X_getctx(atoi(argv[1]));
+ if (argc==1) ctx = vc_get_task_xid(0);
+ else ctx = vc_get_task_xid(atoi(argv[1]));
utilvserver_fmt_int(buf, ctx);