criu/compel/plugins/include/uapi/std/infect.h
Dmitry Safonov 1c0716924b compel/criu: Add __must_check
All those compel functions can fail by various reasons.
It may be status of the system, interruption by user or anything else.
It's really desired to handle as many PIE related errors as possible
otherwise it's hard to analyze statuses of parasite/restorer
and the C/R process.

At least warning for logs should be produced or even C/R stopped.

Signed-off-by: Dmitry Safonov <dima@arista.com>
Signed-off-by: Andrei Vagin <avagin@gmail.com>
2020-02-04 12:39:04 -08:00

22 lines
605 B
C

#ifndef COMPEL_PLUGIN_STD_INFECT_H__
#define COMPEL_PLUGIN_STD_INFECT_H__
#include "common/compiler.h"
extern int parasite_get_rpc_sock(void);
extern int __must_check parasite_service(unsigned int cmd, void *args);
/*
* Must be supplied by user plugins.
*/
extern int __must_check parasite_daemon_cmd(int cmd, void *args);
extern int __must_check parasite_trap_cmd(int cmd, void *args);
extern void parasite_cleanup(void);
/*
* FIXME: Should be supplied by log module.
*/
extern void log_set_fd(int fd);
extern void log_set_loglevel(unsigned int level);
#endif /* COMPEL_PLUGIN_STD_INFECT_H__ */